Skip to content

Commit

Permalink
Merge pull request #5 from konsulin-id/feature/setup-deployment
Browse files Browse the repository at this point in the history
feat: publish package to nexus repository
  • Loading branch information
dhanifajar15 authored Aug 13, 2024
2 parents af8b8f8 + e981f4f commit 7f6de66
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 218 deletions.
112 changes: 0 additions & 112 deletions .github/workflows/build_test_lint.yml

This file was deleted.

69 changes: 0 additions & 69 deletions .github/workflows/deploy_app.yml

This file was deleted.

37 changes: 0 additions & 37 deletions .github/workflows/deploy_docs.yml

This file was deleted.

36 changes: 36 additions & 0 deletions .github/workflows/publish_app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Smart Form App Publish Workflow
on:
push:
branches: ['main']

jobs:
publish:
name: Publish App to Nexus Repository
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version:
- 20.16
os:
- ubuntu-latest
steps:
- name: Prepare Checkout
uses: actions/checkout@v3

- name: Set Up Node JS
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
check-latest: false

- name: Installing Packages
run: npm install

- name: Set up npm
run: |
echo "registry=https://repository.konsulin.care/repository/smart-forms/" > .npmrc
echo "//repository.konsulin.care/repository/smart-forms/:_authToken=${{ SECRETS.NPM_TOKEN }}" >> .npmrc
- name: Publish npm package
run: npm publish

5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
{
"name": "smart-forms",
"version": "1.0.0",
"scripts": {
"lint": "eslint -c .eslintrc.json .",
"lint-fix": "eslint -c .eslintrc.json --fix .",
"check-formatting": "prettier --check ."
},
"publishConfig":{
"registry": "https://repository.konsulin.care/repository/smart-forms/"
},
"workspaces": [
"apps/smart-forms-app",
Expand Down

0 comments on commit 7f6de66

Please sign in to comment.