-
Notifications
You must be signed in to change notification settings - Fork 59
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
Lf/new functions template #205
Conversation
@@ -0,0 +1,9 @@ | |||
# Salesforce App |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might be helpful if we have some get started info for users here. @smaddox-sf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good suggestion that should be addressed as a separate work item for now.
@@ -107,12 +107,13 @@ export interface LightningTestOptions extends TemplateOptions { | |||
export interface ProjectOptions extends TemplateOptions { | |||
projectname: string; | |||
defaultpackagedir: string; | |||
defaultfunctionsdir: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where is this used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not. It was part of another approach. Fixed!
@@ -204,6 +204,18 @@ export default class ProjectGenerator extends SfdxGenerator<ProjectOptions> { | |||
); | |||
} | |||
} | |||
|
|||
// tslint:disable-next-line:no-unused-expression | |||
if (template === 'functions') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need the tslint disable here? seems like it runs fine without it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
…sforcedx-templates into lf/newFunctionsTemplate
…sforcedx-templates into lf/newFunctionsTemplate
…sforcedx-templates into lf/newFunctionsTemplate
{ | ||
"orgName": "<%= company %>", | ||
"edition": "Developer", | ||
"features": [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think functions has it's own scratch org feature that we should add here.Let me confirm the name for it.
packages/templates/src/templates/project/functions/ScratchDef.json
Outdated
Show resolved
Hide resolved
…json There is a specific scratch org feature for functions. Co-authored-by: lcampos <lcamposguajardo@gmail.com>
@@ -35,7 +35,7 @@ export default class Project extends TemplateCommand { | |||
description: MessageUtil.get('ProjectTemplateFlagDescription'), | |||
longDescription: MessageUtil.get('ProjectTemplateFlagLongDescription'), | |||
default: 'standard', | |||
options: ['standard', 'empty', 'analytics'] | |||
options: ['standard', 'empty', 'analytics', 'functions'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is correct but I wonder we might want to keep the functionality strictly to the library for now so that it's not surfaced through the cli command options. What do you think @smaddox-sf ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Circling back from our conversation during standup, we need to remove the changes on this PR that are on the plugin-templates
module. The rest can be merged cc @LisandroFernandezSF
…sforcedx-templates into lf/newFunctionsTemplate
* Adding Functions template * Adding test for the new template * Removing unnecessary lines and spaces * Adding Functions template * Adding test for the new template * Removing unnecessary lines and spaces * Removing unnecessary type and tslint line * Removing unnecessary type * Update packages/templates/src/templates/project/functions/ScratchDef.json There is a specific scratch org feature for functions. Co-authored-by: lcampos <lcamposguajardo@gmail.com> * I remove code that affects the plugin * empty commit Co-authored-by: lcampos <lcamposguajardo@gmail.com>
* Update contribution guide (#190) * add coding and commit guidelines, start developing doc * update contributing docs * update develop doc, update launch config * Update CONTRIBUTING.md * Update README.md * Update coding-guidelines.md * Update commit-guidelines.md * Update developing.md * Update CONTRIBUTING.md Co-authored-by: Xiaoyi Chen <xchen@salesforce.com> * Update commit-guidelines.md * Update developing.md * Update developing.md * update contributing docs * Update developing.md Co-authored-by: Emily Kapner <ekapner@salesforce.com> * port #186 (#199) * Update dev scripts (#200) @W-8017763@ * Remove @salesforce/templates from yarn.lock (#201) @W-8017763@ * Lf/new functions template (#205) * Adding Functions template * Adding test for the new template * Removing unnecessary lines and spaces * Adding Functions template * Adding test for the new template * Removing unnecessary lines and spaces * Removing unnecessary type and tslint line * Removing unnecessary type * Update packages/templates/src/templates/project/functions/ScratchDef.json There is a specific scratch org feature for functions. Co-authored-by: lcampos <lcamposguajardo@gmail.com> * I remove code that affects the plugin * empty commit Co-authored-by: lcampos <lcamposguajardo@gmail.com> Co-authored-by: Emily Kapner <ekapner@salesforce.com> Co-authored-by: lcampos <lcamposguajardo@gmail.com> Co-authored-by: Lisandro Fernandez <70181900+LisandroFernandezSF@users.noreply.github.com>
What does this PR do?
This PR is adding a new project template which copies the same structure than 'empty', but includes a 'functions' folder
What issues does this PR fix or reference?
W-7958785