Skip to content

Commit

Permalink
revert changes to configs because Mark didn't know how this Thor feat…
Browse files Browse the repository at this point in the history
…ure worked. ;)
  • Loading branch information
mvandervoord committed Apr 12, 2024
1 parent 4e031f7 commit 1e384ae
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -441,10 +441,10 @@ from within the root directory of your project.
Are you afraid of losing all your local changes when this happens? You
can prevent Ceedling from updating your project file by adding
`--no_configs`.
`--no-configs`.
```shell
> ceedling upgrade --local --no_configs YourSweetProject
> ceedling upgrade --local --no-configs YourSweetProject
```
## Git integration
Expand Down
6 changes: 2 additions & 4 deletions bin/cli.rb
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,7 @@ def help(command=nil)
desc "new NAME [DEST]", "Create a new project structure at optional DEST path"
method_option :local, :type => :boolean, :default => false, :desc => DOC_LOCAL_FLAG
method_option :docs, :type => :boolean, :default => false, :desc => DOC_DOCS_FLAG
method_option :no_configs, :type => :boolean, :default => false, :desc => "Install starter configuration files"
method_option :noconfigs, :type => :boolean, :default => false, :hide => true
method_option :configs, :type => :boolean, :default => true, :desc => "Install starter configuration files"
method_option :force, :type => :boolean, :default => false, :desc => "Ignore any existing project and recreate destination"
method_option :debug, :type => :boolean, :default => false, :hide => true
method_option :gitignore, :type => :boolean, :default => false, :desc => "Create a gitignore file for ignoring ceedling generated files"
Expand All @@ -178,7 +177,7 @@ def help(command=nil)
#{LONGDOC_DOCS_FLAG}
• `--no_configs` don't copy a starter project configuration file into the root of the
• `--configs` add a starter project configuration file into the root of the
new project.
• `--force` overrides protectons preventing a new project from overwriting an
Expand All @@ -191,7 +190,6 @@ def new(name, dest=nil)
_dest = dest.dup() if !dest.nil?

_options[:verbosity] = options[:debug] ? VERBOSITY_DEBUG : nil
_options[:no_configs] = options[:no_configs] || options[:noconfigs] || false

@handler.new_project( CEEDLING_ROOT, _options, name, _dest )
end
Expand Down
2 changes: 1 addition & 1 deletion bin/cli_handler.rb
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def new_project(ceedling_root, options, name, dest)
@helper.copy_docs( ceedling_root, dest ) if options[:docs]

# Copy / set up project file
@helper.create_project_file( ceedling_root, dest, options[:local] ) unless options[:no_configs]
@helper.create_project_file( ceedling_root, dest, options[:local] ) if options[:configs]

# Copy Git Ignore file
@actions._copy_file( File.join(ceedling_root,'assets','default_gitignore'), File.join(dest,'.gitignore'), :force => true ) if options[:gitignore]
Expand Down

0 comments on commit 1e384ae

Please sign in to comment.