Closed munjalpatel closed 10 months ago
I just took a look. It looks like --minimal
invokes this:
def filter_for_minimal(entries)
return entries unless @minimal
filtered = entries.reject { |entry| entry.path.includes?(".js") || entry.path.includes?(".scss") || entry.path.includes?("package.json") ||
entry.path.includes?("config/webpack") || entry.path.includes?("home_controller") }
filtered.reject { |entry| entry.path.includes?("src/views") && !entry.path.includes?("mailer") }
end
In other words, it looks like minimal rejects the following files/extensions:
.js
.scss
package.json
config/webpack
home_controller
views
mailer
I just generated an app. It looks like the only thing making it through is views/layouts/mailer
which makes sense as API's may still need mail functionality.
What functionality were you expecting that did not happen?
I know it's already too late and there are no updates in this issue, but I suppose folders/files likepublic/assets/i18n/views/layouts
shouldn't be generated in a minimal project as per the OP reqs..
I just tried this on version Amber CLI (amberframework.org) - v1.4.1
and that flag has been removed. Considering it no longer exists, we can safely close this.
ubuntu:~$ amber new myapp --minimal
Parsing Error: The --minimal option is unknown.
/
amber new [OPTIONS] NAME
Generates a new Amber project
Arguments:
NAME name/path of project
Options:
-d Select the database database engine, can be one of: pg | mysql | sqlite
(default: pg)
--no-color Disable colored output
--no-deps Does not install dependencies, this avoids running shards update
-r Use a named recipe. See documentation at https://docs.amberframework.org/amber/cli/recipes.
-t Selects the template engine language, can be one of: slang | ecr
(default: slang)
-y, --assume-yes Assume yes to disable interactive mode
-h, --help show this help
We can close this bug as "Not Valid" given it is three years old and the feature is no longer supported.
@codered thank you!
Description
When I try to create an api-only app using newly introduced
--minimal
flag, it still creates the full app.Steps to Reproduce
Expected behavior: An app that does not have any view + static asset to be created.
Actual behavior: Full app is created.
Reproduces how often: Can reproduce 100% of times.
Versions
Full logs: