Skip to content
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

feature: Add SAM Globals parsing #43

Merged
merged 4 commits into from
Jul 4, 2020
Merged

feature: Add SAM Globals parsing #43

merged 4 commits into from
Jul 4, 2020

Conversation

nhammond101
Copy link
Contributor

Adds the ability to use Globals properties within the functions.

My use case was a fallback to the CodeUri property specified in the Globals section of the SAM template.

Unfortunately, the upstream Cloudform repo doesn't yet support SAM templates fully, hence the @ts-ignore but there's an open ticket to support SAM. This PR shouldn't interfere with that change if it's comes.

Nick Hammond added 2 commits July 2, 2020 13:39
Allows fallbacks to the CodeUri and Handler properties for functions
Copy link
Owner

@studds studds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for submitting this request, a few small changes and things to look over. If you can make the changes then I'll merge and publish asap.

libs/sam/src/build/get-entries-from-cloudformation.ts Outdated Show resolved Hide resolved
libs/sam/src/build/get-entries-from-cloudformation.ts Outdated Show resolved Hide resolved
Nick Hammond added 2 commits July 3, 2020 12:48
Holding the types in a separate module should allow for easier removal when the upstream types incorporate `Globals` from the SAM template
Utilise the new types lib for using the `Globals` property
@nhammond101 nhammond101 requested a review from studds July 3, 2020 11:57
Copy link
Owner

@studds studds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks

@studds studds merged commit 6edf7d2 into studds:master Jul 4, 2020
@studds
Copy link
Owner

studds commented Jul 4, 2020

I've tested this out at seems fine, v0.7.0 published to npm now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants