Skip to content

Commit

Permalink
Optimize workflows, stable, nightly and manually
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperKali committed Jan 29, 2025
1 parent d766a66 commit b018511
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 35 deletions.
22 changes: 5 additions & 17 deletions .github/workflows/immortalwrt-builder-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,10 @@ jobs:
run: |
cp -r dts/${{env.BANANAWRT_RELEASE}}/* ${{ runner.workspace }}/immortalwrt/target/linux/mediatek/dts/
- name: Update Package Feeds
run: |
cd ${{ runner.workspace }}/immortalwrt
- name: Update and Install Package Feeds
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
./scripts/feeds update -a
- name: Install Package Feeds
run: |
cd ${{ runner.workspace }}/immortalwrt
./scripts/feeds install -a
- name: Apply Custom Configuration
Expand All @@ -92,28 +88,20 @@ jobs:
./scripts/feeds install -p additional_pack -a
- name: Diffconfig with current configuration
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
cd ${{ runner.workspace }}/immortalwrt
./scripts/diffconfig.sh > diffconfig
curl https://downloads.immortalwrt.org/releases/$REPO_BRANCH/targets/mediatek/filogic/config.buildinfo
cat diffconfig >> config.buildinfo
mv config.buildinfo .config
[ -n "$REPO_BRANCH" ] && sed -i \
-e 's|^CONFIG_VERSION_REPO=.*|CONFIG_VERSION_REPO="https://downloads.immortalwrt.org/releases/'"$REPO_BRANCH"'"|g' \
.config
- name: Download Required Packages
run: |
cd ${{ runner.workspace }}/immortalwrt
make defconfig
make download -j$(nproc)
find dl -size -1024c -exec ls -l {} \;
find dl -size -1024c -exec rm -f {} \;
- name: Build Firmware
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
cd ${{ runner.workspace }}/immortalwrt
make -j$(nproc) || make -j1 V=s
grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
echo "FILE_DATE=$(date +'%Y%m%d%H%M')" >> $GITHUB_ENV
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/immortalwrt-builder-selfhost.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ jobs:
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
make -j$(nproc) || make -j$(nproc) || make -j1 V=s
make -j$(nproc) || make -j1 V=s
grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
echo "FILE_DATE=$(date +'%Y%m%d%H%M')" >> $GITHUB_ENV
Expand Down
22 changes: 5 additions & 17 deletions .github/workflows/immortalwrt-builder-stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,10 @@ jobs:
run: |
cp -r dts/${{ env.BANANAWRT_RELEASE }}/* ${{ runner.workspace }}/immortalwrt/target/linux/mediatek/dts/
- name: Update Package Feeds
run: |
cd ${{ runner.workspace }}/immortalwrt
- name: Update and Install Package Feeds
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
./scripts/feeds update -a
- name: Install Package Feeds
run: |
cd ${{ runner.workspace }}/immortalwrt
./scripts/feeds install -a
- name: Apply Custom Configuration
Expand All @@ -92,28 +88,20 @@ jobs:
./scripts/feeds install -p additional_pack -a
- name: Diffconfig with current configuration
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
cd ${{ runner.workspace }}/immortalwrt
./scripts/diffconfig.sh > diffconfig
curl https://downloads.immortalwrt.org/releases/$REPO_BRANCH/targets/mediatek/filogic/config.buildinfo
cat diffconfig >> config.buildinfo
mv config.buildinfo .config
[ -n "$REPO_BRANCH" ] && sed -i \
-e 's|^CONFIG_VERSION_REPO=.*|CONFIG_VERSION_REPO="https://downloads.immortalwrt.org/releases/'"$REPO_BRANCH"'"|g' \
.config
- name: Download Required Packages
run: |
cd ${{ runner.workspace }}/immortalwrt
make defconfig
make download -j$(nproc)
find dl -size -1024c -exec ls -l {} \;
find dl -size -1024c -exec rm -f {} \;
- name: Build Firmware
working-directory: ${{ runner.workspace }}/immortalwrt
run: |
cd ${{ runner.workspace }}/immortalwrt
make -j$(nproc) || make -j1 V=s
grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
echo "FILE_DATE=$(date +'%Y%m%d%H%M')" >> $GITHUB_ENV
Expand Down

0 comments on commit b018511

Please sign in to comment.