fixing bug with config generation, started fixing add command, next commit command
This commit is contained in:
		@@ -150,6 +150,7 @@ func AddFiles(input string, inputType string, ignore common.FileTypes, m *engine
 | 
			
		||||
		m.Info().Msg("Adding all files...")
 | 
			
		||||
		filepath.Walk(workingDir, func(path string, info os.FileInfo, err error) error {
 | 
			
		||||
			if err != nil {
 | 
			
		||||
				fmt.Println("Err accessing path: ", err)
 | 
			
		||||
				return fmt.Errorf("failure accessing path %s", err)
 | 
			
		||||
			}
 | 
			
		||||
			if info.IsDir() {
 | 
			
		||||
@@ -178,9 +179,12 @@ func AddFiles(input string, inputType string, ignore common.FileTypes, m *engine
 | 
			
		||||
			if relativePath == "." { //Ignoring current directory
 | 
			
		||||
				return nil
 | 
			
		||||
			}
 | 
			
		||||
			fmt.Println("Adding file to repo: ", path)
 | 
			
		||||
			m.Info().Msgf("Adding file to repo: %s", path)
 | 
			
		||||
			err = m.AddFileToRepo(relativePath)
 | 
			
		||||
			if err != nil {
 | 
			
		||||
				return fmt.Errorf("unable to add file to repo: %s", err)
 | 
			
		||||
				fmt.Printf("unable to add file to repo: %s\n", err)
 | 
			
		||||
				return nil
 | 
			
		||||
			}
 | 
			
		||||
			trackedFiles = append(trackedFiles, relativePath)
 | 
			
		||||
			return nil
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user