From 6bb67e2e5725309459966a2dcf4cd4195a52a0e3 Mon Sep 17 00:00:00 2001 From: Netkas Date: Thu, 18 Nov 2021 15:02:11 -0500 Subject: [PATCH] Added CI --- ....intellivoid.socialvoid_web_assets.ppm.yml | 37 ++++++++++++++ ...void.socialvoid_web_assets.ppm_release.yml | 49 +++++++++++++++++++ 2 files changed, 86 insertions(+) create mode 100644 .github/workflows/net.intellivoid.socialvoid_web_assets.ppm.yml create mode 100644 .github/workflows/net.intellivoid.socialvoid_web_assets.ppm_release.yml diff --git a/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm.yml b/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm.yml new file mode 100644 index 0000000..e88a021 --- /dev/null +++ b/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm.yml @@ -0,0 +1,37 @@ +name: PPM Compile Socialvoid-Web Assets + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + + - name: Add repoistory for PHP 8.0 + run: sudo add-apt-repository ppa:ondrej/php + - name: Install PHP 8.0 + run: sudo apt-get install php8.0 php8.0-curl php8.0-mbstring php8.0-tokenizer php8.0-fileinfo + + - uses: actions/checkout@v2 + with: + repository: intellivoid/ppm + ref: "production" + token: ${{ secrets.PPM_ACCESS_TOKEN }} + - name: Install PPM + run: sudo ./install + - name: Configuring PPM + run: sudo ppm --github-add-pat --alias="system" --token="${{ secrets.PPM_ACCESS_TOKEN }}" + - uses: actions/checkout@master + - name: Make build directory + run: mkdir build + + - name: Prepare Socialvoid-Web Assets + run: ppm --generate-package="assets" + - name: Compile Socialvoid-Web Assets + run: ppm --no-intro --verbose --compile="assets" --directory="build" + - name: Install Socialvoid-Web Assets + run: sudo -H ppm --no-prompt --fix-conflict --verbose --install="build/net.intellivoid.socialvoid_web_assets.ppm" \ No newline at end of file diff --git a/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm_release.yml b/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm_release.yml new file mode 100644 index 0000000..ad488d3 --- /dev/null +++ b/.github/workflows/net.intellivoid.socialvoid_web_assets.ppm_release.yml @@ -0,0 +1,49 @@ +name: PPM Release Socialvoid-Web Assets + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + + - name: Add repoistory for PHP 8.0 + run: sudo add-apt-repository ppa:ondrej/php + - name: Install PHP 8.0 + run: sudo apt-get install php8.0 php8.0-curl php8.0-mbstring php8.0-tokenizer php8.0-fileinfo + + - uses: actions/checkout@v2 + with: + repository: intellivoid/ppm + ref: "production" + token: ${{ secrets.PPM_ACCESS_TOKEN }} + - name: Install PPM + run: sudo ./install + - name: Configuring PPM + run: sudo ppm --github-add-pat --alias="system" --token="${{ secrets.PPM_ACCESS_TOKEN }}" + - uses: actions/checkout@master + - name: Make build directory + run: mkdir build + + - name: Prepare Socialvoid-Web Assets + run: ppm --generate-package="assets" + - name: Compile Socialvoid-Web Assets + run: ppm --no-intro --verbose --compile="assets" --directory="build" + - name: Install Socialvoid-Web Assets + run: sudo -H ppm --no-prompt --fix-conflict --verbose --install="build/net.intellivoid.socialvoid_web_assets.ppm" + + - name: Get Package Version + run: echo package_version=$(ppm --get-version="build/net.intellivoid.socialvoid_web_assets.ppm") >> $GITHUB_ENV + - name: Create Release + uses: softprops/action-gh-release@v1 + with: + files: build/net.intellivoid.socialvoid_web_assets.ppm + name: "Socialvoid-Web Assets v${{ env.package_version }}" + tag_name: "v${{ env.package_version }}" + body: "Compiled PPM package for Socialvoid-Web Assets, version ${{ env.package_version }}" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file