From 63015f5227da458d0b2bb69f38d29f81e6c352b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=AA=E3=81=A4=E3=81=8D?= Date: Tue, 17 Jan 2023 02:10:40 -0800 Subject: [PATCH] Initial commit --- .github/dependabot.yml | 6 ++ .github/workflows/build.yml | 106 ++++++++++++++++++++++++++++++++++++ LICENSE | 21 +++++++ README.md | 1 + 4 files changed, 134 insertions(+) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/build.yml create mode 100644 LICENSE create mode 100644 README.md diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..1230149 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "daily" diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..3aa0dd0 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,106 @@ +name: build + +on: + push: + branches: + - '**' + tags: + - '**' + pull_request: + branches: + - '**' + +jobs: + build: + name: Build + + runs-on: ubuntu-latest + + strategy: + fail-fast: false + matrix: + include: + - arch: x64 + lib: lib64 + platform: linux/amd64 + - arch: ia32 + lib: lib + platform: linux/amd64 + - arch: arm64 + lib: lib64 + platform: linux/arm64 + - arch: arm + lib: lib + platform: linux/arm64 + + steps: + - uses: actions/checkout@v3 + with: + repository: 'sass/dart-sass' + ref: ${{ startsWith(github.ref, 'refs/tags/') && github.ref || '' }} + + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + image: tonistiigi/binfmt:master # need qemu >= 7.0.0 + + - name: Build + run: | + docker run --rm -i \ + --platform ${{ matrix.platform }} \ + --privileged \ + --volume $PWD:$PWD \ + --workdir $PWD \ + ghcr.io/dart-android/dart <<'EOF' + set -e + export DART_SDK=/system/${{ matrix.lib }}/dart + export PATH=$DART_SDK/bin:$PATH + dart pub get + dart run grinder pkg-standalone-android-${{ matrix.arch }} + EOF + + - name: Upload Artifact + uses: actions/upload-artifact@v3 + with: + name: build-${{ matrix.arch }} + path: build/*.tar.gz + if-no-files-found: error + + release: + name: Release + + if: github.event.repository.fork == false && startsWith(github.ref, 'refs/tags/') + + needs: [build] + + runs-on: ubuntu-latest + + permissions: + contents: write + + steps: + - name: Download Artifact + uses: actions/download-artifact@v3 + with: + name: build-x64 + + - name: Download Artifact + uses: actions/download-artifact@v3 + with: + name: build-ia32 + + - name: Download Artifact + uses: actions/download-artifact@v3 + with: + name: build-arm64 + + - name: Download Artifact + uses: actions/download-artifact@v3 + with: + name: build-arm + + - name: Release + uses: softprops/action-gh-release@v1 + with: + files: | + *.tar.gz diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..0bc3cdb --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2023 Dart for musl (unofficial) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..35ce8fe --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +# dart-sass