Skip to content

Commit 5ae1479

Browse files
authored
Install v0.19.0 shell magic (#116)
1 parent 320fa5c commit 5ae1479

File tree

5 files changed

+164
-118
lines changed

5 files changed

+164
-118
lines changed

.github/workflows/ci.yml

Lines changed: 24 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
env:
5959
VERBOSE: ${{ matrix.verbose }}
6060
- run: tea --env --dump
61-
- run: tea test
61+
- run: tea node --check ./action.js #TODO use xc
6262
- run: which tea
6363
- run: find "$(tea --silent --prefix)"/tea.xyz
6464
- run: find /opt/tea.xyz -name v0.? -o -name v0.?? -mindepth 1 -maxdepth 1 -print0 | xargs -0 test -L
@@ -91,7 +91,6 @@ jobs:
9191
id: tea
9292
with:
9393
prefix: ${{ matrix.prefix }}
94-
target: test
9594
srcroot: ${{ matrix.srcroot || github.workspace }}
9695

9796
- run: test -n "$VERSION"
@@ -165,25 +164,34 @@ jobs:
165164
- run: apt-get update && apt-get --yes install curl
166165
- run: ./install.sh --yes
167166

168-
sudo-required:
167+
#FIXME can't test for this without a way to install without magic in headless mode
168+
# sudo-required:
169+
# runs-on: ubuntu-latest
170+
# steps:
171+
# - uses: actions/checkout@v3
172+
# - run: sudo chmod go-w /usr/local/bin
173+
# # ^^ we run as `runner` but this dir has 999 perms
174+
# - run: ./install.sh --yes
175+
# - run: .github/smoke-test.sh
176+
# - run: test $(which tea) = /usr/local/bin/tea
177+
#
178+
# no-usr-local:
179+
# runs-on: ubuntu-latest
180+
# steps:
181+
# - uses: actions/checkout@v3
182+
# - run: sudo rm -rf /usr/local # this is fine, right?
183+
# - run: sudo chmod 777 /usr # and this
184+
# - run: ./install.sh --yes
185+
# - run: .github/smoke-test.sh
186+
# - run: test $(which tea) = /usr/local/bin/tea
187+
188+
tea-with-magic-is-in-expected-place:
169189
runs-on: ubuntu-latest
170190
steps:
171191
- uses: actions/checkout@v3
172-
- run: sudo chmod go-w /usr/local/bin
173-
# ^^ we run as `runner` but this dir has 999 perms
174192
- run: ./install.sh --yes
175193
- run: .github/smoke-test.sh
176-
- run: test $(which tea) = /usr/local/bin/tea
177-
178-
no-usr-local:
179-
runs-on: ubuntu-latest
180-
steps:
181-
- uses: actions/checkout@v3
182-
- run: sudo rm -rf /usr/local # this is fine, right?
183-
- run: sudo chmod 777 /usr # and this
184-
- run: ./install.sh --yes
185-
- run: .github/smoke-test.sh
186-
- run: test $(which tea) = /usr/local/bin/tea
194+
- run: test $(which tea) = $HOME/.tea/tea.xyz/v0/bin/tea
187195

188196
installs-if-gitea-found:
189197
runs-on: ubuntu-latest

.github/workflows/vx-tagger.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,5 @@ jobs:
77
steps:
88
- uses: actions/checkout@v3
99
- uses: fischerscode/tagger@v0
10+
with:
11+
prefix: v

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[`install.sh`](./install.sh) is delivered when you `curl tea.xyz`.
44

5-
# GitHub Action 0.10.1
5+
# GitHub Action 0.11.0
66

77
This repository also provides the `tea` GitHub Action.
88

@@ -23,13 +23,15 @@ sh <(curl tea.xyz)
2323
```
2424

2525
```sh
26-
sh <(curl tea.xyz) +charm.sh/gum gum spin -- sleep 5
26+
sh <(curl tea.xyz) gum spin -- sleep 5
2727

2828
# - if tea is installed, uses that installation to run gum
2929
# - if tea is *not* installed, downloads gum and its deps to a safe and
3030
# temporary location and executes the command
3131
```
3232

33+
> NOTE we omit `https://` for clarity, *please* include it in all your usages.
34+
3335
### Options
3436

3537
* `sh <(curl tea.xyz) --yes` assumes affirmative for all prompts
@@ -41,17 +43,15 @@ sh <(curl tea.xyz) +charm.sh/gum gum spin -- sleep 5
4143

4244
```yaml
4345
- uses: teaxyz/setup@v0
44-
with:
45-
target: build
4646
```
4747
48-
Is the equivalent of `tea build`, ie. runs the executable markdown from your
49-
project’s README for the `# build` section. Of course we install your
50-
dependencies first.
48+
Installs tea, your dependencies (listed in your `README.md`), adds your deps
49+
to `PATH` and exports some other *tea’ish* variables like `VERSION`.
50+
51+
See [`action.yml`] for all inputs and outputs.
5152

52-
There is no need to specify a target, `- uses: teaxyz/setup@v0` by itself
53-
installs your deps and exports some variables like `VERSION`. See [`action.yml`]
54-
for all inputs and outputs.
53+
> NOTE: we cannot install our shell magic, so if eg. `npx` is not listed in
54+
> your dependencies you will need to invoke it as `tea npx` to use it.
5555

5656
[action.yml]: ../../action.yml
5757

action.yml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,6 @@ name: tea/setup
22
description: >
33
Installs tea.xyz to your GitHub Actions runner.
44
inputs:
5-
target:
6-
description: >
7-
The executable markdown target.
8-
required: false
95
prefix:
106
description: >
117
Where tea installs.
@@ -27,7 +23,6 @@ inputs:
2723
2824
You will need this if you depend on the virtual environment tea
2925
provides.
30-
3126
outputs:
3227
version:
3328
description: Your project’s version.

0 commit comments

Comments
 (0)