Skip to content

Commit c551aba

Browse files
POC asdf plugin for documentation
1 parent f03a8f2 commit c551aba

File tree

2 files changed

+5
-43
lines changed

2 files changed

+5
-43
lines changed

.github/actions/build-docs/action.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,17 @@ runs:
1212
- uses: actions/setup-node@v6
1313
with:
1414
node-version: 24
15-
- name: Npm cli install
16-
working-directory: ./docs
17-
run: npm ci
18-
shell: bash
1915
- name: Setup Ruby
2016
uses: ruby/[email protected]
2117
with:
2218
ruby-version: "3.4.7" # Not needed with a .ruby-version file
2319
bundler-cache: false # runs 'bundle install' and caches installed gems automatically
2420
#cache-version: 0 # Increment this number if you need to re-download cached gems
2521
working-directory: "./docs"
22+
- name: "Setup ASDF"
23+
uses: asdf-vm/actions/setup@b7bcd026f18772e44fe1026d729e1611cc435d47 # v4
24+
with:
25+
working-directory: "./src/cloudevents"
2626
- name: Setup Pages
2727
id: pages
2828
uses: actions/configure-pages@v5

src/cloudevents/Makefile

Lines changed: 1 addition & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -140,43 +140,5 @@ asdf-install-test:
140140
@echo "asdf installation complete"
141141

142142
deploy-ci:
143-
echo "=== Setting up environment for CI unit tests ===" && \
144-
curl -LO https://github.com/asdf-vm/asdf/releases/download/v0.18.0/asdf-v0.18.0-linux-amd64.tar.gz && \
145-
tar -xvzf asdf-v0.18.0-linux-amd64.tar.gz -C /usr/local/bin && \
146-
chmod +x /usr/local/bin/asdf && \
147-
pwd && \
148-
ls -la
149-
@echo "from manual test tools versions file contains:"
150-
cat .tool-versions || echo " -> .tool-versions file not found in this directory"
151-
/usr/local/bin/asdf --version
152-
@echo "Setting up asdf environment and adding plugins"
153-
export ASDF_DATA_DIR=$$HOME/.asdf && \
154-
export PATH=$$ASDF_DATA_DIR/shims:$$ASDF_DATA_DIR/bin:/usr/local/bin:$$PATH && \
155-
echo "Adding plugins from .tool-versions" && \
156-
while IFS=' ' read -r plugin version || [ -n "$$plugin" ]; do \
157-
plugin=$$(echo "$$plugin" | xargs); \
158-
first_char=$$(echo "$$plugin" | cut -c1); \
159-
if [ -n "$$plugin" ] && [ "$$first_char" != "#" ]; then \
160-
echo "Adding plugin: $$plugin (version: $$version)" && \
161-
/usr/local/bin/asdf plugin add "$$plugin" 2>&1 || echo " -> Plugin $$plugin already added or failed"; \
162-
fi \
163-
done < .tool-versions && \
164-
echo "Listing available plugins:" && \
165-
/usr/local/bin/asdf plugin list && \
166-
echo "Installing asdf versions" && \
167-
/usr/local/bin/asdf install -v && \
168-
echo "Installed versions:" && \
169-
/usr/local/bin/asdf list && \
170-
echo "Node is at:" && \
171-
whereis node && \
172-
echo "Chosen one is at:" && \
173-
which node && \
174-
echo "Node version is:" && \
175-
node --version && \
176-
npm install && \
177-
echo "=== Finished installing dependencies ===" && \
178-
asdf info && \
179-
asdf current && \
180-
node --version && \
181-
npm --version && \
143+
npm ci
182144
make deploy

0 commit comments

Comments
 (0)