Skip to content

Commit b6ccf47

Browse files
committed
chore: removed the on push master event and fixes #1
1 parent bd9c52a commit b6ccf47

File tree

4 files changed

+15
-23
lines changed

4 files changed

+15
-23
lines changed

.github/workflows/release.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@ name: Release
33
on:
44
schedule:
55
- cron: "0 17 * * *" # run at 5:00 PM UTC
6-
push:
7-
branches:
8-
- "master"
96

107
jobs:
118
release:

.github/workflows/test.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,16 @@ jobs:
1515
uses: actions/setup-node@v1
1616
with:
1717
node_version: 12
18-
# - name: Install
19-
# run: yarn install --frozen-lockfile
20-
# - name: Prepare Npm
21-
# run: sh npm.sh
22-
# env:
23-
# REGISTRY_AUTH_TOKEN: ${{ secrets.REGISTRY_AUTH_TOKEN }}
24-
# REGISTRY_URL: registry.npmjs.org
25-
# - name: Test
26-
# run: npm run test
27-
# env:
28-
# REGISTRY_AUTH_TOKEN: ${{ secrets.REGISTRY_AUTH_TOKEN }}
29-
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Github already has this token by default in repo
30-
# REGISTRY_URL: registry.npmjs.org
18+
- name: Install
19+
run: yarn install --frozen-lockfile
20+
- name: Prepare Npm
21+
run: sh npm.sh
22+
env:
23+
REGISTRY_AUTH_TOKEN: ${{ secrets.REGISTRY_AUTH_TOKEN }}
24+
REGISTRY_URL: registry.npmjs.org
25+
- name: Test
26+
run: npm run test
27+
env:
28+
REGISTRY_AUTH_TOKEN: ${{ secrets.REGISTRY_AUTH_TOKEN }}
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Github already has this token by default in repo
30+
REGISTRY_URL: registry.npmjs.org

createGithubRelease.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,7 @@ const octokit = new Octokit({
88
auth: `token ${githubToken}`
99
});
1010

11-
// when running the action for first time. give the first argument of this as
12-
// createChangelog('2019-02-14')
13-
// and after that, keep it null i.e `createChange()` only
14-
const { body } = createChangelog("2019-02-14");
11+
const { body } = createChangelog();
1512

1613
function createGithubRelease() {
1714
octokit.repos

isNewChanges.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@ const todayDate = `${tyear}-${tmonth}-${tdate}`;
99

1010
async function isNewChange() {
1111
let commits = await fetch(
12-
// temporary adding the "'2019-02-14'", replace it with `yesterdayDate`
13-
// "'2019-02-14'" - is the date of the last release
14-
`https://api.github.com/repos/cssnano/cssnano/commits?branch=master&since=${"2019-02-14"}&until=${todayDate}`
12+
`https://api.github.com/repos/cssnano/cssnano/commits?branch=master&since=${yesterdayDate}&until=${todayDate}`
1513
);
1614
commits = await commits.json();
1715
return Array.isArray(commits) && commits.length > 0;

0 commit comments

Comments
 (0)