2
0

Compare commits

..

6 Commits

Author SHA1 Message Date
e0c7e2a725 Singned commit + source modify
Signed-off-by: Václav Valíček <valicek1994@gmail.com>
2022-06-20 01:49:32 +02:00
Stephan
7bc1195651 exp 2022-03-18 18:49:47 +01:00
Stephan
786c441206 exp 2022-03-18 18:48:12 +01:00
Stephan
558f12143c exp 2022-03-18 18:45:23 +01:00
Stephan
2cd8137eeb exp 2022-03-18 18:39:54 +01:00
Stephan
77f77c3e8b exp 2022-03-18 18:37:35 +01:00
3 changed files with 5 additions and 7 deletions

View File

@@ -48,8 +48,7 @@ module.exports = /*async*/ ({github, context, core}) => {
core.setFailed(`Could not find a GitHub release for tag '${tag}'.`)
return
}
console.log(release)
if (release.draft) {
if (!release.draft) {
core.setFailed(`GitHub release for tag '${tag}' is already published.`)
return
}
@@ -115,7 +114,6 @@ module.exports = /*async*/ ({github, context, core}) => {
owner: context.repo.owner,
repo: context.repo.repo
})
console.log(releases)
const release = firstOrDefault(releases.data, (x) => x.tag_name == tag)
return release
}

View File

@@ -36,11 +36,11 @@ jobs:
await script.validateRelease()
- name: Finalize GitHub release and milestone
if: github.event.inputs.dryrun == false
if: ${{ github.event.inputs.dryrun == 'false' }}
uses: actions/github-script@v5
with:
script: |
const scriptf = require('./.github/workflows/publish-release.js')
const script = scriptf({github, context, core})
//await script.publishRelease()
//await script.closeMilestone()
await script.publishRelease()
await script.closeMilestone()

View File

@@ -19,7 +19,7 @@ Clone the repository with: `git clone https://github.com/zpqrtbnk/test-repo.git
We have test GitHUb pages (from the `gh-pages` branch) at: http://zpqrtbnk.github.io/test-repo/
We have an image in the README (markdown)
![Image](https://raw.github.com/zpqrtbnk/test-repo/master/wtf.jpg)
![Image](wtf.jpg)
We have an image in the README (html)
<img src="./wtf.jpg" />