Skip to content

Commit

Permalink
Add bun (#11)
Browse files Browse the repository at this point in the history
* Add bun

* Fixed Actions
  • Loading branch information
yatish27 authored May 18, 2024
1 parent 47dd648 commit e125160
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 1,167 deletions.
13 changes: 3 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,10 @@ jobs:
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true

- name: Setup Node
uses: actions/setup-node@v4
- uses: oven-sh/setup-bun@v1
with:
node-version: 'latest'
cache: yarn

- name: Install dependencies
run: |
yarn install --frozen-lockfile
bun-version: 1.1.8
- run: bun install
- run: bundle exec rake db:migrate
- run: bundle exec rake test:all
rubocop:
Expand Down
1 change: 0 additions & 1 deletion .nvmrc

This file was deleted.

12 changes: 4 additions & 8 deletions Dockerfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ ENV BUNDLE_PATH /usr/local/bundle
ENV BUNDLE_PATH /usr/local/bundle
ENV GEM_PATH /usr/local/bundle
ENV GEM_HOME /usr/local/bundle
ENV NODE_VERSION=22.1.0
ENV YARN_VERSION=latest
ENV PATH=/usr/local/node/bin:$PATH
ENV BUN_INSTALL /usr/local/bun
ENV PATH $BUN_INSTALL/bin:$PATH

COPY docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh

Expand All @@ -21,10 +20,7 @@ apt-get update
apt-get install -y build-essential libpq-dev curl unzip
EOF

RUN curl -sL https://github.com/nodenv/node-build/archive/master.tar.gz | tar xz -C /tmp/ && \
/tmp/node-build-master/bin/node-build "${NODE_VERSION}" /usr/local/node && \
npm install -g yarn@$YARN_VERSION && \
rm -rf /tmp/node-build-master
RUN curl -fsSL https://bun.sh/install | bash -s -- "bun-v${BUN_VERSION}"

RUN gem install bundler --version "$BUNDLE_VERSION"

Expand All @@ -34,7 +30,7 @@ COPY Gemfile Gemfile.lock ./
COPY package.json ./

RUN bundle check || bundle install --jobs=8
RUN yarn install
RUN bun install

COPY . .

Expand Down
5 changes: 5 additions & 0 deletions bin/shims/vite
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env bash

set -eo pipefail

bunx vite "$@"
Binary file added bun.lockb
Binary file not shown.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,5 @@
},
"devDependencies": {
"tailwindcss": "^3.4.3"
},
"packageManager": "[email protected]+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
}
}
1,146 changes: 0 additions & 1,146 deletions yarn.lock

This file was deleted.

0 comments on commit e125160

Please sign in to comment.