Compare commits
No commits in common. "master" and "eltro_v1.6.0" have entirely different histories.
master
...
eltro_v1.6
2 changed files with 54 additions and 2 deletions
53
appveyor.yml
Normal file
53
appveyor.yml
Normal file
|
@ -0,0 +1,53 @@
|
||||||
|
# version format
|
||||||
|
version: '{build}'
|
||||||
|
|
||||||
|
# branches to build
|
||||||
|
branches:
|
||||||
|
# whitelist
|
||||||
|
only:
|
||||||
|
- master
|
||||||
|
|
||||||
|
# Do not build on tags (GitHub, Bitbucket, GitLab, Gitea)
|
||||||
|
skip_tags: true
|
||||||
|
|
||||||
|
# Maximum number of concurrent jobs for the project
|
||||||
|
max_jobs: 1
|
||||||
|
clone_depth: 1
|
||||||
|
|
||||||
|
# Build worker image (VM template)
|
||||||
|
build_cloud: Docker
|
||||||
|
|
||||||
|
environment:
|
||||||
|
docker_image: node:16-alpine
|
||||||
|
npm_config_cache: /appveyor/projects/cache
|
||||||
|
|
||||||
|
test_script:
|
||||||
|
- sh: |
|
||||||
|
npm test
|
||||||
|
|
||||||
|
on_success:
|
||||||
|
- sh: |
|
||||||
|
if !(apk add curl jq); then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
CURR_VER=$(cat package.json | jq -r .version)
|
||||||
|
if curl -s -X GET -H "Authorization: token $deploytoken" https://git.nfp.is/api/v1/repos/$APPVEYOR_REPO_NAME/releases | grep -o "\"name\"\:\"v${CURR_VER}\"" > /dev/null; then
|
||||||
|
echo "Release already exists, nothing to do.";
|
||||||
|
else
|
||||||
|
echo "Creating release on gitea"
|
||||||
|
RELEASE_RESULT=$(curl \
|
||||||
|
-X POST \
|
||||||
|
-H "Authorization: token $deploytoken" \
|
||||||
|
-H "Content-Type: application/json" \
|
||||||
|
https://git.nfp.is/api/v1/repos/$APPVEYOR_REPO_NAME/releases \
|
||||||
|
-d "{\"tag_name\":\"v${CURR_VER}\",\"name\":\"v${CURR_VER}\",\"body\":\"Automatic release from Appveyor from ${APPVEYOR_REPO_COMMIT} :\n\n${APPVEYOR_REPO_COMMIT_MESSAGE}\"}")
|
||||||
|
RELEASE_ID=$(echo $RELEASE_RESULT | jq -r .id)
|
||||||
|
if [ "$RELEASE_ID" == "null" ]; then
|
||||||
|
echo $RELEASE_RESULT
|
||||||
|
else
|
||||||
|
echo "Created release ${RELEASE_ID}"
|
||||||
|
fi
|
||||||
|
echo '//registry.npmjs.org/:_authToken=${npmtoken}' > ~/.npmrc
|
||||||
|
echo "Publishing new version to npm"
|
||||||
|
npm publish
|
||||||
|
fi
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "eltro",
|
"name": "eltro",
|
||||||
"version": "1.6.1",
|
"version": "1.6.0",
|
||||||
"description": "Eltro is a tiny no-dependancy test framework for node",
|
"description": "Eltro is a tiny no-dependancy test framework for node",
|
||||||
"main": "index.mjs",
|
"main": "index.mjs",
|
||||||
"types": "eltro.d.ts",
|
"types": "eltro.d.ts",
|
||||||
|
@ -50,7 +50,6 @@
|
||||||
"eltro": "./cli.mjs"
|
"eltro": "./cli.mjs"
|
||||||
},
|
},
|
||||||
"files": [
|
"files": [
|
||||||
"eltro.d.ts",
|
|
||||||
"index.mjs",
|
"index.mjs",
|
||||||
"cli.mjs",
|
"cli.mjs",
|
||||||
"README.md",
|
"README.md",
|
||||||
|
|
Loading…
Reference in a new issue