mirror of
https://github.com/vlang/v.git
synced 2025-09-13 22:42:26 +03:00
tools: add .github/workflows/show_manual_release_cmd.vsh
, to make cross platform testing of the release process easier
This commit is contained in:
parent
4885b815f4
commit
13282cc1e1
1 changed files with 27 additions and 0 deletions
27
.github/workflows/show_manual_release_cmd.vsh
vendored
Normal file
27
.github/workflows/show_manual_release_cmd.vsh
vendored
Normal file
|
@ -0,0 +1,27 @@
|
|||
import os
|
||||
import time
|
||||
import math
|
||||
import term
|
||||
|
||||
now := time.now()
|
||||
year := now.year
|
||||
week := int(math.ceil(f64(now.year_day()) / 7.0))
|
||||
|
||||
mut remote_name := 'origin'
|
||||
mut release_tag := 'weekly.${year}.${week}'
|
||||
|
||||
if os.args.len > 1 {
|
||||
remote_name = os.args[1]
|
||||
}
|
||||
|
||||
if os.args.len > 2 {
|
||||
release_tag = os.args[2]
|
||||
}
|
||||
|
||||
println('## Usage: show_manual_release_cmd.vsh [REMOTE] [TAGNAME]')
|
||||
println('## current remote_name: ${remote_name}')
|
||||
println('## current release_tag: ${release_tag}')
|
||||
println('## ▼▼▼ ${term.ecolorize(term.yellow, 'run the following, to make a new github release')} ▼▼▼ ')
|
||||
|
||||
git_cmd := 'git tag -s -m "releases: ${release_tag}" ${release_tag} && git push --atomic ${remote_name} ${release_tag}"'
|
||||
println(git_cmd)
|
Loading…
Add table
Add a link
Reference in a new issue