Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -119,4 +119,4 @@ venv.bak/
# Companion stack config
integration/config/file_to_s3_map_modified.json

.tmp_schema.json
.tmp
15 changes: 11 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,10 @@ black:

black-check:
# Checking latest schema was generated (run `make schema` if this fails)
python samtranslator/schema/schema.py > .tmp_schema.json
diff -u samtranslator/schema/schema.json .tmp_schema.json
rm .tmp_schema.json
mkdir -p .tmp
python samtranslator/schema/schema.py --sam-schema .tmp/sam.schema.json --cfn-schema samtranslator/schema/cloudformation.schema.json --unified-schema .tmp/unified.schema.json
diff -u samtranslator/schema/schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/unified.schema.json .tmp/unified.schema.json
black --check setup.py samtranslator/* tests/* integration/* bin/*.py
bin/json-format.py --check tests integration samtranslator/policy_templates_data
bin/yaml-format.py --check tests
Expand All @@ -44,15 +45,21 @@ lint:
prepare-companion-stack:
pytest -v --no-cov integration/setup -m setup

update-cfn-schema:
curl -o samtranslator/schema/cloudformation.schema.json https://raw.githubusercontent.com/awslabs/goformation/master/schema/cloudformation.schema.json

schema:
python samtranslator/schema/schema.py > samtranslator/schema/schema.json
python samtranslator/schema/schema.py --sam-schema samtranslator/schema/schema.json --cfn-schema samtranslator/schema/cloudformation.schema.json --unified-schema samtranslator/schema/unified.schema.json

# Command to run everytime you make changes to verify everything works
dev: test

# Verifications to run before sending a pull request
pr: black-check lint init dev

clean:
rm -r .tmp

define HELP_MESSAGE

Usage: $ make [TARGETS]
Expand Down
Loading