-
Notifications
You must be signed in to change notification settings - Fork 438
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
environment vars & cli options to specify dotfiles #616
Comments
Why can't we:
? What would |
@grant I have started implementing the following design:
Handling scriptIds directly on the command line is clumsy IMHO. And about half a dozen issues are likely to be addressed with cli option/environment vars overrides. I am also considering an "extended" .clasp.json interface which would allow to hold it all in one file. I haven't yet fully thought it over, but it could look something like the following: {
// "legacy" properties
"scriptId": "scriptId",
"rootDir": "rootDir",
"projectId": "projectId",
"fileExtension": "fileExtension",
"filePushOrder": "filePushOrder",
// "extended properties
"env": {
// same "legacy" properties
"claspIgnore": "pathAndNameToClaspIgnore",
"clasprc": "pathAndNameToClaspRc",
"manifest": "pathAndNameToAppsScriptJson",
}
} There you could do commands like |
.clasp.json
name and path to be a CLI parameter
The goal of this feature request is to enable the user in specifying which/where the following configuration files to be used by Clasp:
This sould be possible through:
The rules to resolve a config file path would be by priority order:
values can be absolute and relative path to a directory containing a config file of the default name (i.e. |
@grant comments? thoughts? |
I can’t really support feature that don’t have at least 10 users or solves a key use case. I would maybe fork clasp if you really can’t use bash commands to do this and want to add it to the CLI. |
I want to "git" my gas project, but I need to add some hardcode id´s (google sheet) to the git repository, it would be great to have environment variables inside .clasp.json to avoid the versioning of this id´s |
A design/PR that only included the following would be fine:
no flags, ignore file would be in the project. Be sure to document the variables. |
@chechedotmx would environment variables to specify |
@grant why no flags (cli options)? You're spoiling all the fun! |
Want to start simple. Also flags may conflict with existing command flags. |
@grant I already did the full PR, so limiting to only |
Sounds good @PopGoesTheWza |
In a fashion similar to
tsc --project
andtslint --project
which allow to specify which (and where) your project configuration file to be used, it would be nice (and useful) to be able to define on the command line different clasp configuration.Expected Behavior
clasp push --project dev.json
clasp push --project prod.json
Actual Behavior
(some kludgy workaround with additional folders and intricate path references)
Steps to Reproduce the Problem
Specifications
node -v
): 10clasp -v
): latestThe text was updated successfully, but these errors were encountered: