File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change 4646 - type : node
4747 version : 18.x
4848 - type : node
49+ version : 20.x
50+ - type : bun
4951 runs-on : ubuntu-latest
5052 timeout-minutes : 3
5153 steps :
6668 uses : actions/setup-node@v3
6769 with :
6870 node-version : ${{ matrix.environment.version }}
71+ - name : Use Bun ${{ matrix.environment.version }}
72+ if : matrix.environment.type == 'bun'
73+ uses : oven-sh/setup-bun@v1
6974 - name : Install dependencies
7075 if : matrix.environment.type == 'node'
7176 run : npm ci
@@ -102,6 +107,15 @@ jobs:
102107 gen_code ./dist/src/index.js > test.mjs
103108 node test.mjs | tee /dev/stderr | grep -q true
104109 ;;
110+ bun)
111+ # Workaround: https://github.com/oven-sh/bun/issues/1590
112+ dependencies=`jq -r '.dependencies|to_entries|map("\(.key)@\(.value)")|join(" ")' package.json`
113+ ( set -x; mkdir /tmp/bun && cd "$_" && ls -lah && bun install -p "$dependencies" && rm -rf `pwd`; )
114+ bun install -p --ignore-scripts
115+ bun build src/index.ts --target bun > ts-postgres.js
116+ gen_code ./ts-postgres.js > test.mjs
117+ bun test.mjs | tee /dev/stderr | grep -q true
118+ ;;
105119 esac
106120 env :
107121 ENVIRONMENT : ${{ matrix.environment.type }}
You can’t perform that action at this time.
0 commit comments