Duplicate snapshot #5

Open
opened 2023-08-10 22:24:14 +02:00 by EndMove · 0 comments
Owner

.drone.yml Lines 1 to 81 in 7ca678b9c2
---
kind: pipeline
type: docker
name: snapshot
trigger:
event:
- push
branch:
exclude:
- master
steps:
- name: publish-snapshot
image: node:18
environment:
GITEA_TOKEN:
from_secret: gitea_token
commands:
- export VERSION=$(node -p "require('./package.json').version") || echo "1.0.0"
- SNAPSHOT="$(echo $VERSION)-snapshot.${DRONE_BUILD_NUMBER}"
- echo $VERSION
- echo $SNAPSHOT
- npm ci
- npm version $SNAPSHOT
- npm publish --tag snapshot
# - npm dist-tag add @ioprojects/eslint-config@$SNAPSHOT snapshot
---
kind: pipeline
type: docker
name: checkup
trigger:
event:
- push
- promote
branch:
- master
steps:
- name: package-checkup
image: node:18
commands:
- export DATA=$(node -p "require('./package.json')") || echo "No Data Found"
- echo "Package Data :"
- echo $DATA
---
kind: pipeline
type: docker
name: release
trigger:
event:
- promote
branch:
- master
depends_on:
- checkup
environment:
VERSION: ${VERSION}
steps:
- name: publish-release
image: node:18
environment:
GITEA_TOKEN:
from_secret: gitea_token
commands:
- git fetch --tags
- npm ci
- echo $(node -p "require('./package.json').version")
- echo $VERSION
- npm version $VERSION
- git push --set-upstream origin master
- git tag -l
- git push --set-upstream origin $(node -p "require('./package.json').version")
- npm publish

A snapshot is created when a new branch is created and when commit are made. Should we use PR trigger event instead ?

image

https://git.endmove.eu/IO-ProjectsOfficial/eslint-config/src/commit/7ca678b9c2808b3d4a1092d7e323efe7897a0f5f/.drone.yml#L1-L81 A snapshot is created when a new branch is created and when commit are made. Should we use PR trigger event instead ? ![image](/attachments/7dc779df-6293-48b7-b33a-42708f27a1a6)
5.8 KiB
EndMove added the
Kind/Breaking
Reviewed
Confirmed
Priority
Low
labels 2023-08-10 22:24:14 +02:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: IO-ProjectsOfficial/eslint-config#5
No description provided.