From 87dac3e83a919ec19983d216d106f0c5461c16af Mon Sep 17 00:00:00 2001 From: anirudha4 Date: Thu, 15 Jul 2021 19:34:34 +0530 Subject: [PATCH 01/22] removed immutablejs to handle immutability, updated tests for respected files --- generators/container/reducer.js.hbs | 5 ++--- generators/container/reducer.test.js.hbs | 3 +-- generators/container/selectors.js.hbs | 2 +- generators/container/selectors.test.js.hbs | 5 ++--- 4 files changed, 6 insertions(+), 9 deletions(-) diff --git a/generators/container/reducer.js.hbs b/generators/container/reducer.js.hbs index e633aa6..5087390 100644 --- a/generators/container/reducer.js.hbs +++ b/generators/container/reducer.js.hbs @@ -4,10 +4,9 @@ * */ import produce from 'immer' -import { fromJS } from 'immutable' import { createActions } from 'reduxsauce' -export const initialState = fromJS({}) +export const initialState = {} export const { Types: {{ camelCase name }}Types, Creators: {{ camelCase name }}Creators } = createActions({ defaultAction: ['somePayload'] @@ -18,7 +17,7 @@ export const {{ camelCase name }}Reducer = (state = initialState, action) => produce(state, (/* draft */) => { switch (action.type) { case {{ camelCase name}}Types.DEFAULT_ACTION: - return state.set('somePayload', action.somePayload) + return {...state, action.payload} default: return state } diff --git a/generators/container/reducer.test.js.hbs b/generators/container/reducer.test.js.hbs index fbdb10b..354e20d 100644 --- a/generators/container/reducer.test.js.hbs +++ b/generators/container/reducer.test.js.hbs @@ -1,5 +1,4 @@ // import produce from 'immer' -import { fromJS } from 'immutable'; import { {{ camelCase name }}Reducer, {{ camelCase name }}Types, initialState } from '../reducer' /* eslint-disable default-case, no-param-reassign */ @@ -14,7 +13,7 @@ describe('{{ properCase name }} reducer tests', () => { }) it('should return the update the state when an action of type DEFAULT is dispatched', () => { - const expectedResult = fromJS(state.toJS()).set('somePayload', 'Mohammed Ali Chherawalla') + const expectedResult = {...state, somePayload: 'Mohammed Ali Chherawalla'} expect( {{ camelCase name }}Reducer(state, { type: {{ camelCase name}}Types.DEFAULT_ACTION, diff --git a/generators/container/selectors.js.hbs b/generators/container/selectors.js.hbs index 69dcf73..0bd2898 100644 --- a/generators/container/selectors.js.hbs +++ b/generators/container/selectors.js.hbs @@ -5,7 +5,7 @@ import { initialState } from './reducer' * Direct selector to the {{ camelCase name }} state domain */ -const select{{ properCase name }}Domain = state => (state.{{ camelCase name }} || initialState).toJS() +const select{{ properCase name }}Domain = state => (state.{{ camelCase name }} || initialState) const makeSelect{{ properCase name }} = () => createSelector(select{{ properCase name }}Domain, substate => substate) diff --git a/generators/container/selectors.test.js.hbs b/generators/container/selectors.test.js.hbs index f690cd1..8b86b3e 100644 --- a/generators/container/selectors.test.js.hbs +++ b/generators/container/selectors.test.js.hbs @@ -1,4 +1,3 @@ -import { fromJS } from 'immutable' import { select{{ properCase name }}Domain } from '../selectors' describe('{{ properCase name }} selector tests', () => { @@ -6,11 +5,11 @@ describe('{{ properCase name }} selector tests', () => { beforeEach(() => { mockedState = { - {{ camelCase name }}: fromJS({}) + {{ camelCase name }}: {} } }) it('should select the user state', () => { - expect(select{{ properCase name }}Domain(mockedState)).toEqual(mockedState.{{ camelCase name }}.toJS()) + expect(select{{ properCase name }}Domain(mockedState)).toEqual(mockedState.{{ camelCase name }} }) }) \ No newline at end of file From 1919f669bdd7ece2adeb6deaf50808b6b7eb6e4c Mon Sep 17 00:00:00 2001 From: anirudha4 Date: Fri, 16 Jul 2021 09:24:25 +0530 Subject: [PATCH 02/22] fixed some issues --- generators/container/reducer.js.hbs | 2 +- generators/container/selectors.test.js.hbs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/generators/container/reducer.js.hbs b/generators/container/reducer.js.hbs index 5087390..5beac5f 100644 --- a/generators/container/reducer.js.hbs +++ b/generators/container/reducer.js.hbs @@ -17,7 +17,7 @@ export const {{ camelCase name }}Reducer = (state = initialState, action) => produce(state, (/* draft */) => { switch (action.type) { case {{ camelCase name}}Types.DEFAULT_ACTION: - return {...state, action.payload} + return {...state, somePayload: action.payload} default: return state } diff --git a/generators/container/selectors.test.js.hbs b/generators/container/selectors.test.js.hbs index 8b86b3e..296672f 100644 --- a/generators/container/selectors.test.js.hbs +++ b/generators/container/selectors.test.js.hbs @@ -10,6 +10,6 @@ describe('{{ properCase name }} selector tests', () => { }) it('should select the user state', () => { - expect(select{{ properCase name }}Domain(mockedState)).toEqual(mockedState.{{ camelCase name }} + expect(select{{ properCase name }}Domain(mockedState)).toEqual(mockedState.{{ camelCase name }}) }) }) \ No newline at end of file From afab0fd89066eb50176b0414d2b67345772f55f6 Mon Sep 17 00:00:00 2001 From: Aniruddha Gandhare Date: Fri, 16 Jul 2021 11:56:49 +0530 Subject: [PATCH 03/22] fixed isses in reducer and selector --- generators/container/reducer.js.hbs | 2 +- generators/container/selectors.js.hbs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/generators/container/reducer.js.hbs b/generators/container/reducer.js.hbs index 5beac5f..cc0a0dd 100644 --- a/generators/container/reducer.js.hbs +++ b/generators/container/reducer.js.hbs @@ -17,7 +17,7 @@ export const {{ camelCase name }}Reducer = (state = initialState, action) => produce(state, (/* draft */) => { switch (action.type) { case {{ camelCase name}}Types.DEFAULT_ACTION: - return {...state, somePayload: action.payload} + return {...state, somePayload: action.somePayload} default: return state } diff --git a/generators/container/selectors.js.hbs b/generators/container/selectors.js.hbs index 0bd2898..3a8018f 100644 --- a/generators/container/selectors.js.hbs +++ b/generators/container/selectors.js.hbs @@ -5,7 +5,7 @@ import { initialState } from './reducer' * Direct selector to the {{ camelCase name }} state domain */ -const select{{ properCase name }}Domain = state => (state.{{ camelCase name }} || initialState) +const select{{ properCase name }}Domain = state => state.{{ camelCase name }} || initialState const makeSelect{{ properCase name }} = () => createSelector(select{{ properCase name }}Domain, substate => substate) From f5f5d9842a9e64f1cec2be9132b3e4e991eaa025 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 14:20:57 +0530 Subject: [PATCH 04/22] created cd.yml --- .github/workflows/cd.yml | 49 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 .github/workflows/cd.yml diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml new file mode 100644 index 0000000..9c8986b --- /dev/null +++ b/.github/workflows/cd.yml @@ -0,0 +1,49 @@ +name: Npm publish + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [13.x] + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + registry-url: 'https://registry.npmjs.org' + - name: Install dependencies + run: yarn + env: + CI: true + - name: Build + run: yarn webpack:prod && yarn pack + env: + CI: true + - name: Commit changes + uses: EndBug/add-and-commit@v7 + with: + author_name: Gitflow + author_email: git@wednesday.is + message: 'Created bin' + add: 'bin/' + - name: Bump version + run: | + git config --global user.email "git@wednesday.is" + git config --global user.name "Git" + npm version patch -m 'Bump up' + - name: Push changes + uses: ad-m/github-push-action@master + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + branch: ${{ github.ref }} + - name: Publish + run: yarn publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} From a459c65bc5f5a454cca9a510325be7f21463fd05 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 16:58:56 +0530 Subject: [PATCH 05/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..c5adecc --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,29 @@ +name: Npm publish + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [13.x] + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + registry-url: 'https://registry.npmjs.org' + - name: Bump version + run: | + git config --global user.email "git@wednesday.is" + git config --global user.name "Git" + npm version patch -m 'Bump up' + - name: Publish + run: yarn publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} From 3dd66d59fc130f9fd0d93cd567e6100e7b9206b5 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:00:28 +0530 Subject: [PATCH 06/22] Delete cd.yml --- .github/workflows/cd.yml | 49 ---------------------------------------- 1 file changed, 49 deletions(-) delete mode 100644 .github/workflows/cd.yml diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml deleted file mode 100644 index 9c8986b..0000000 --- a/.github/workflows/cd.yml +++ /dev/null @@ -1,49 +0,0 @@ -name: Npm publish - -on: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [13.x] - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - registry-url: 'https://registry.npmjs.org' - - name: Install dependencies - run: yarn - env: - CI: true - - name: Build - run: yarn webpack:prod && yarn pack - env: - CI: true - - name: Commit changes - uses: EndBug/add-and-commit@v7 - with: - author_name: Gitflow - author_email: git@wednesday.is - message: 'Created bin' - add: 'bin/' - - name: Bump version - run: | - git config --global user.email "git@wednesday.is" - git config --global user.name "Git" - npm version patch -m 'Bump up' - - name: Push changes - uses: ad-m/github-push-action@master - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - branch: ${{ github.ref }} - - name: Publish - run: yarn publish - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} From bb2212627f99bf6780958d68af9268206632144f Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:00:34 +0530 Subject: [PATCH 07/22] Delete npm-publish.yml --- .github/workflows/npm-publish.yml | 29 ----------------------------- 1 file changed, 29 deletions(-) delete mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml deleted file mode 100644 index c5adecc..0000000 --- a/.github/workflows/npm-publish.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: Npm publish - -on: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [13.x] - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node-version }} - registry-url: 'https://registry.npmjs.org' - - name: Bump version - run: | - git config --global user.email "git@wednesday.is" - git config --global user.name "Git" - npm version patch -m 'Bump up' - - name: Publish - run: yarn publish - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} From 37680741ab6973e490870022315a8a3d4b189b6d Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:02:25 +0530 Subject: [PATCH 08/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 34 +++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..b72d33d --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,34 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + - run: npm ci + - run: npm test + + publish-npm: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 424cfcdbea9694c0952d20256b6c92681655b690 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:04:16 +0530 Subject: [PATCH 09/22] Delete npm-publish.yml --- .github/workflows/npm-publish.yml | 34 ------------------------------- 1 file changed, 34 deletions(-) delete mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml deleted file mode 100644 index b72d33d..0000000 --- a/.github/workflows/npm-publish.yml +++ /dev/null @@ -1,34 +0,0 @@ -# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created -# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages - -name: Node.js Package - -on: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - - run: npm ci - - run: npm test - - publish-npm: - needs: build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - registry-url: https://registry.npmjs.org/ - - run: npm ci - - run: npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From aaf3e7ecf80b44a923281e4fffe774557ee5beb3 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:05:49 +0530 Subject: [PATCH 10/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..98c05a7 --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,23 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + push: + branches: + - master + +jobs: + publish-npm: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: yarn ci + - run: yarn publish + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From b0baacc10aae3d1d2939141635eca0337f73b5d6 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:07:01 +0530 Subject: [PATCH 11/22] Delete .github/workflows directory --- .github/workflows/npm-publish.yml | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml deleted file mode 100644 index 98c05a7..0000000 --- a/.github/workflows/npm-publish.yml +++ /dev/null @@ -1,23 +0,0 @@ -# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created -# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages - -name: Node.js Package - -on: - push: - branches: - - master - -jobs: - publish-npm: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - registry-url: https://registry.npmjs.org/ - - run: yarn ci - - run: yarn publish - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 6f2d82f02e4cca069d9aa9fa1cd8cd3a21801346 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:10:21 +0530 Subject: [PATCH 12/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..262d70d --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,23 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + push: + branches: + - master + +jobs: + publish-npm: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: yarn install --frozen-lockfile + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 28bf25840deb05bb4dd2570346bb8a5e5f09fe33 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:18:23 +0530 Subject: [PATCH 13/22] Delete npm-publish.yml --- .github/workflows/npm-publish.yml | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml deleted file mode 100644 index 262d70d..0000000 --- a/.github/workflows/npm-publish.yml +++ /dev/null @@ -1,23 +0,0 @@ -# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created -# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages - -name: Node.js Package - -on: - push: - branches: - - master - -jobs: - publish-npm: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - registry-url: https://registry.npmjs.org/ - - run: yarn install --frozen-lockfile - - run: npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 97e6d146ae39f116aaabc5f86695b3178911d49c Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:50:04 +0530 Subject: [PATCH 14/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 34 +++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..772769e --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,34 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + - run: yarn install + - run: yarn test + + publish-npm: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: yarn install + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 4c7414bd96eb7edf3d465e367c833ba3274e2c02 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:52:57 +0530 Subject: [PATCH 15/22] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 772769e..07b5594 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -17,7 +17,6 @@ jobs: with: node-version: 14 - run: yarn install - - run: yarn test publish-npm: needs: build From 9223671d2b72748e73941c806f436a53a78d82dd Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:56:34 +0530 Subject: [PATCH 16/22] Delete .github/workflows directory --- .github/workflows/npm-publish.yml | 33 ------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml deleted file mode 100644 index 07b5594..0000000 --- a/.github/workflows/npm-publish.yml +++ /dev/null @@ -1,33 +0,0 @@ -# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created -# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages - -name: Node.js Package - -on: - push: - branches: - - master - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - - run: yarn install - - publish-npm: - needs: build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - registry-url: https://registry.npmjs.org/ - - run: yarn install - - run: npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 4b218219b3c42388578593bc394707c021770164 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 17:59:14 +0530 Subject: [PATCH 17/22] Create npm-publish.yml --- .github/workflows/npm-publish.yml | 33 +++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..07b5594 --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,33 @@ +# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created +# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages + +name: Node.js Package + +on: + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + - run: yarn install + + publish-npm: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + with: + node-version: 14 + registry-url: https://registry.npmjs.org/ + - run: yarn install + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 235d951b896aad7346cf478455fd8aa8bfc21713 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Fri, 16 Jul 2021 18:01:37 +0530 Subject: [PATCH 18/22] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 07b5594..655a7f4 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -28,6 +28,6 @@ jobs: node-version: 14 registry-url: https://registry.npmjs.org/ - run: yarn install - - run: npm publish + - run: yarn publish env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From 30f8eafc5cc3c48ba5412b3933ccf46f993794ac Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Sat, 17 Jul 2021 11:47:15 +0530 Subject: [PATCH 19/22] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 655a7f4..5654b76 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -1,7 +1,4 @@ -# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created -# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages - -name: Node.js Package +name: react-floki on: push: @@ -9,17 +6,7 @@ on: - master jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 - with: - node-version: 14 - - run: yarn install - publish-npm: - needs: build runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 From 976f718577008e60881a892a5046d3e909bbf7ec Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Sat, 17 Jul 2021 11:53:25 +0530 Subject: [PATCH 20/22] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 5654b76..c9520d1 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -14,7 +14,6 @@ jobs: with: node-version: 14 registry-url: https://registry.npmjs.org/ - - run: yarn install - run: yarn publish env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From f3288e149f3f85d2abfe516129b3c21485f46412 Mon Sep 17 00:00:00 2001 From: aniruddhagandhare <87136310+aniruddhagandhare@users.noreply.github.com> Date: Sat, 17 Jul 2021 12:18:29 +0530 Subject: [PATCH 21/22] Update npm-publish.yml --- .github/workflows/npm-publish.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index c9520d1..5aee446 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -14,6 +14,17 @@ jobs: with: node-version: 14 registry-url: https://registry.npmjs.org/ - - run: yarn publish + - name: bump version + run: | + git config --global user.email "git@wednesday.is" + git config --global user.name "Git" + npm version patch -m 'Bump up' + - name: Push changes + uses: ad-m/github-push-action@master + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + branch: ${{ github.ref }} + - name: Publish + run: yarn publish env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} From d89e6d60f5764d83c50421462624e525d14df5f1 Mon Sep 17 00:00:00 2001 From: Git Date: Sat, 17 Jul 2021 06:54:53 +0000 Subject: [PATCH 22/22] Bump up --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c93d911..5ca2664 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-floki", - "version": "1.0.83", + "version": "1.0.84", "description": "A React component, container and test generation library", "repository": { "type": "git",