-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from DanMad/develop
General Updates
- Loading branch information
Showing
24 changed files
with
1,741 additions
and
2,137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"comments": false, | ||
"presets": [ | ||
"@babel/preset-env", | ||
"@babel/preset-typescript" | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/sh | ||
|
||
PACKAGE_VERSION=$(cat package.json | jq -r .version) | ||
GITHUB_ENDPOINT="${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/git/ref/tags/v${PACKAGE_VERSION}" | ||
GITHUB_ENDPOINT_STATUS=$( | ||
curl \ | ||
-LI $GITHUB_ENDPOINT \ | ||
-o /dev/null \ | ||
-w '%{http_code}\n' \ | ||
-sH "Authorization: token ${GITHUB_TOKEN}" \ | ||
) | ||
|
||
if [ "$GITHUB_ENDPOINT_STATUS" = "404" ] | ||
then | ||
echo "This version doesn't exist" | ||
elif [ "$GITHUB_ENDPOINT_STATUS" = "200" ] | ||
then | ||
echo "This version already exists" | ||
exit 1 | ||
else | ||
echo "There was a problem connecting to GitHub" | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/bin/sh | ||
|
||
PACKAGE_VERSION=$(cat package.json | jq -r .version) | ||
PAYLOAD="{ \ | ||
\"tag_name\": \"v${PACKAGE_VERSION}\", \ | ||
\"target_commitish\": \"${GITHUB_SHA}\", \ | ||
\"name\": \"v${PACKAGE_VERSION}\", | ||
\"body\": \"Release Version ${PACKAGE_VERSION}\", \ | ||
\"draft\": false, \ | ||
\"prerelease\": false \ | ||
}" | ||
GITHUB_ENDPOINT="${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/releases" | ||
GITHUB_ENDPOINT_STATUS=$( | ||
curl \ | ||
-H "Content-Type:application/json" $GITHUB_ENDPOINT \ | ||
-o /dev/null \ | ||
-w '%{http_code}\n' \ | ||
-d "${PAYLOAD}" \ | ||
-sH "Authorization: token ${GITHUB_TOKEN}" \ | ||
) | ||
|
||
if [ "$GITHUB_ENDPOINT_STATUS" = "201" ] | ||
then | ||
echo "This version was released" | ||
elif [ "$GITHUB_ENDPOINT_STATUS" = "404" ] | ||
then | ||
echo "This version wasn't released" | ||
exit 1 | ||
else | ||
echo "There was a problem connecting to GitHub" | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
|
||
name: Pull Request (main) | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
check_package_version: | ||
name: Check Package Version | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
- run: | | ||
chmod +x .github/scripts/check-package-version.sh | ||
.github/scripts/check-package-version.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
|
||
name: Push (main) | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
create_github_release: | ||
name: Create GitHub Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
- run: | | ||
chmod +x .github/scripts/create-github-release.sh | ||
.github/scripts/create-github-release.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
# Artwork | ||
*.fig | ||
*.psd | ||
*.sketch | ||
# Bundle | ||
# dist | ||
|
||
# Dependencies | ||
node_modules | ||
# Logs | ||
*.log | ||
|
||
# MacOS | ||
# Operating System | ||
.DS_Store | ||
Thumbs.db | ||
|
||
# Packages | ||
node_modules |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
{ | ||
"**/*": "prettier --write" | ||
"package.json": "sort-package-json", | ||
"{,src/**/,types/**/}*.{js,json,md,ts}": "prettier --write" | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,4 @@ | ||
{ | ||
"arrowParens": "always", | ||
"bracketSpacing": true, | ||
"printWidth": 80, | ||
"semi": true, | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "all", | ||
"useTabs": false | ||
"trailingComma": "all" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.