File tree Expand file tree Collapse file tree 2 files changed +16
-13
lines changed Expand file tree Collapse file tree 2 files changed +16
-13
lines changed Original file line number Diff line number Diff line change @@ -81,20 +81,23 @@ func NewMainApp(appVer AppVersion) *cli.Command {
8181	app .EnableShellCompletion  =  true 
8282	app .Flags  =  []cli.Flag {
8383		& cli.StringFlag {
84- 			Name :    "custom-path" ,
85- 			Aliases : []string {"C" },
86- 			Usage :   "Set custom path (defaults to '{WorkPath}/custom')" ,
84+ 			Name :      "custom-path" ,
85+ 			Aliases :   []string {"C" },
86+ 			TakesFile : true ,
87+ 			Usage :     "Set custom path (defaults to '{WorkPath}/custom')" ,
8788		},
8889		& cli.StringFlag {
89- 			Name :    "config" ,
90- 			Aliases : []string {"c" },
91- 			Value :   setting .CustomConf ,
92- 			Usage :   "Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')" ,
90+ 			Name :      "config" ,
91+ 			Aliases :   []string {"c" },
92+ 			TakesFile : true ,
93+ 			Value :     setting .CustomConf ,
94+ 			Usage :     "Set custom config file (defaults to '{WorkPath}/custom/conf/app.ini')" ,
9395		},
9496		& cli.StringFlag {
95- 			Name :    "work-path" ,
96- 			Aliases : []string {"w" },
97- 			Usage :   "Set Gitea's working path (defaults to the Gitea's binary directory)" ,
97+ 			Name :      "work-path" ,
98+ 			Aliases :   []string {"w" },
99+ 			TakesFile : true ,
100+ 			Usage :     "Set Gitea's working path (defaults to the Gitea's binary directory)" ,
98101		},
99102	}
100103	// these sub-commands need to use config file 
Original file line number Diff line number Diff line change @@ -9,9 +9,9 @@ function __fish_gitea_no_subcommand --description 'Test if there has been any su
99    return  0
1010end 
1111
12- complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -f    - l-s  C -r  -d  ' Set custom path (defaults to \' {WorkPath}/custom\' )' 
13- complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -f    - l-s  c -r  -d  ' Set custom config file (defaults to \' {WorkPath}/custom/conf/app.ini\' )' 
14- complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -f    - l-s  w -r  -d  ' Set Gitea\' s working path (defaults to the Gitea\' s binary directory)' 
12+ complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -l  custom-path -s  C -r  -d  ' Set custom path (defaults to \' {WorkPath}/custom\' )' 
13+ complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -l  config -s  c -r  -d  ' Set custom config file (defaults to \' {WorkPath}/custom/conf/app.ini\' )' 
14+ complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -l  work-path -s  w -r  -d  ' Set Gitea\' s working path (defaults to the Gitea\' s binary directory)' 
1515complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -f  -l  help  -s  h -d  ' show help' 
1616complete  -c  gitea -n  ' __fish_gitea_no_subcommand' -f  -l  version -s  v -d  ' print the version' 
1717complete  -x  -c  gitea -n  ' __fish_gitea_no_subcommand' -a  ' help' -d  ' Shows a list of commands or help for one command' 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments