Compare commits

..

No commits in common. "caff604d953064c4678b0fbcdc18b808ff52cd43" and "c6c81ddece32158a1e1fc40d1f7dd2fb4c2cc247" have entirely different histories.

4 changed files with 7 additions and 10 deletions

View File

@ -21,27 +21,27 @@ jobs:
- name: Set branch name - name: Set branch name
id: branch id: branch
run: echo "BRANCH_NAME=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> "$GITHUB_ENV" run: echo "::set-output name=BRANCH_NAME::${GITHUB_REF##*/}"
- name: Fix base URL - name: Fix base URL
if: env.BRANCH_NAME != 'master' && github.repository_owner == 'Rosettea' if: steps.branch.outputs.BRANCH_NAME != 'master' && github.repository_owner == 'Rosettea'
run: sed -i "s%baseURL = 'https://rosettea.github.io/Hilbish/'%baseURL = 'https://rosettea.github.io/Hilbish/versions/${{ env.BRANCH_NAME }}'%" website/config.toml run: sed -i "s%baseURL = 'https://rosettea.github.io/Hilbish/'%baseURL = 'https://rosettea.github.io/Hilbish/versions/${{ steps.branch.outputs.BRANCH_NAME }}'%" website/config.toml
- name: Build - name: Build
run: 'cd website && hugo --minify' run: 'cd website && hugo --minify'
- name: Deploy - name: Deploy
if: env.BRANCH_NAME == 'master' && github.repository_owner == 'Rosettea' if: steps.branch.outputs.BRANCH_NAME == 'master' && github.repository_owner == 'Rosettea'
uses: peaceiris/actions-gh-pages@v3 uses: peaceiris/actions-gh-pages@v3
with: with:
github_token: ${{ secrets.GITHUB_TOKEN }} github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./website/public publish_dir: ./website/public
keep_files: true keep_files: true
- name: Deploy - name: Deploy
if: env.BRANCH_NAME != 'master' && github.repository_owner == 'Rosettea' if: steps.branch.outputs.BRANCH_NAME != 'master' && github.repository_owner == 'Rosettea'
uses: peaceiris/actions-gh-pages@v3 uses: peaceiris/actions-gh-pages@v3
with: with:
github_token: ${{ secrets.GITHUB_TOKEN }} github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./website/public publish_dir: ./website/public
destination_dir: versions/${{ env.BRANCH_NAME }} destination_dir: versions/${{ steps.branch.outputs.BRANCH_NAME }}
keep_files: true keep_files: true

2
api.go
View File

@ -2,7 +2,6 @@
// The Hilbish module includes the core API, containing // The Hilbish module includes the core API, containing
// interfaces and functions which directly relate to shell functionality. // interfaces and functions which directly relate to shell functionality.
// #field ver The version of Hilbish // #field ver The version of Hilbish
// #field goVersion The version of Go that Hilbish was compiled with
// #field user Username of the user // #field user Username of the user
// #field host Hostname of the machine // #field host Hostname of the machine
// #field dataDir Directory for Hilbish data files, including the docs and default modules // #field dataDir Directory for Hilbish data files, including the docs and default modules
@ -111,7 +110,6 @@ func hilbishLoad(rtm *rt.Runtime) (rt.Value, func()) {
} }
util.SetFieldProtected(fakeMod, mod, "ver", rt.StringValue(getVersion())) util.SetFieldProtected(fakeMod, mod, "ver", rt.StringValue(getVersion()))
util.SetFieldProtected(fakeMod, mod, "goVersion", rt.StringValue(runtime.Version()))
util.SetFieldProtected(fakeMod, mod, "user", rt.StringValue(username)) util.SetFieldProtected(fakeMod, mod, "user", rt.StringValue(username))
util.SetFieldProtected(fakeMod, mod, "host", rt.StringValue(host)) util.SetFieldProtected(fakeMod, mod, "host", rt.StringValue(host))
util.SetFieldProtected(fakeMod, mod, "home", rt.StringValue(curuser.HomeDir)) util.SetFieldProtected(fakeMod, mod, "home", rt.StringValue(curuser.HomeDir))

View File

@ -13,7 +13,6 @@ interfaces and functions which directly relate to shell functionality.
## Interface fields ## Interface fields
- `ver`: The version of Hilbish - `ver`: The version of Hilbish
- `goVersion`: The version of Go that Hilbish was compiled with
- `user`: Username of the user - `user`: Username of the user
- `host`: Hostname of the machine - `host`: Hostname of the machine
- `dataDir`: Directory for Hilbish data files, including the docs and default modules - `dataDir`: Directory for Hilbish data files, including the docs and default modules

View File

@ -106,7 +106,7 @@ func main() {
} }
if *verflag { if *verflag {
fmt.Printf("Hilbish %s\nCompiled with %s\n", getVersion(), runtime.Version()) fmt.Printf("Hilbish %s\n", getVersion())
os.Exit(0) os.Exit(0)
} }