From e7b8c7e8b89252cf88fd9719724277abd6d9d973 Mon Sep 17 00:00:00 2001 From: Manpreet Singh Date: Mon, 15 Nov 2021 17:33:38 -0800 Subject: [PATCH] Fedora 35 builds (#1323) * Fedora 35 * Update docs/install/linux.markdown Co-authored-by: Wez Furlong --- .github/workflows/gen_fedora35.yml | 85 ++++++++++++++ .github/workflows/gen_fedora35_continuous.yml | 106 ++++++++++++++++++ .github/workflows/gen_fedora35_tag.yml | 74 ++++++++++++ ci/generate-workflows.py | 1 + ci/subst-release-info.py | 2 + docs/install/linux.markdown | 5 +- 6 files changed, 271 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/gen_fedora35.yml create mode 100644 .github/workflows/gen_fedora35_continuous.yml create mode 100644 .github/workflows/gen_fedora35_tag.yml diff --git a/.github/workflows/gen_fedora35.yml b/.github/workflows/gen_fedora35.yml new file mode 100644 index 000000000..f47962b4b --- /dev/null +++ b/.github/workflows/gen_fedora35.yml @@ -0,0 +1,85 @@ +name: fedora35 + +on: + pull_request: + branches: + - main + paths-ignore: + - ".cirrus.yml" + - "docs/*" + - "ci/build-docs.sh" + - "ci/generate-docs.py" + - "ci/subst-release-info.py" + - ".github/workflows/pages.yml" + - ".github/ISSUE_TEMPLATE/*" + - "**/*.md" + +jobs: + build: + runs-on: "ubuntu-latest" + container: "fedora:35" + steps: + - name: "Install git" + shell: bash + run: "yum install -y git" + - name: "Install curl" + shell: bash + run: "yum install -y curl" + - name: "Ensure /run/sshd exists" + shell: bash + run: "mkdir -p /run/sshd" + - name: "Install openssh-server" + shell: bash + run: "yum install -y openssh-server" + - name: "checkout repo" + uses: actions/checkout@v2 + with: + submodules: "recursive" + - name: "Fetch tags" + shell: bash + run: "git fetch --depth=1 origin +refs/tags/*:refs/tags/*" + - name: "Fetch tag/branch history" + shell: bash + run: "git fetch --prune --unshallow" + - name: "Install Rust" + uses: actions-rs/toolchain@v1 + with: + profile: "minimal" + toolchain: "stable" + override: true + components: "rustfmt" + env: + ACTIONS_ALLOW_UNSECURE_COMMANDS: "true" + - name: "Cache cargo" + uses: actions/cache@v2.1.6 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: "fedora35-None-2-${{ runner.os }}-${{ hashFiles('**/Cargo.lock') }}-cargo" + - name: "Install System Deps" + shell: bash + run: "env PATH=$PATH ./get-deps" + - name: "Check formatting" + shell: bash + run: "cargo fmt --all -- --check" + - name: "Build (Release mode)" + shell: bash + run: "cargo build --all --release" + - name: "Test (Release mode)" + shell: bash + run: "cargo test --all --release" + - name: "Package" + shell: bash + run: "bash ci/deploy.sh" + - name: "Move Package for artifact upload" + shell: bash + run: | + mkdir pkg_ + mv ~/rpmbuild/RPMS/*/*.rpm pkg_ + - name: "Upload artifact" + uses: actions/upload-artifact@master + with: + name: "fedora35" + path: "pkg_" diff --git a/.github/workflows/gen_fedora35_continuous.yml b/.github/workflows/gen_fedora35_continuous.yml new file mode 100644 index 000000000..252fc99a0 --- /dev/null +++ b/.github/workflows/gen_fedora35_continuous.yml @@ -0,0 +1,106 @@ +name: fedora35_continuous + +on: + schedule: + - cron: "10 3 * * *" + push: + branches: + - main + paths-ignore: + - ".cirrus.yml" + - "docs/**" + - "ci/build-docs.sh" + - "ci/generate-docs.py" + - "ci/subst-release-info.py" + - ".github/workflows/pages.yml" + - ".github/ISSUE_TEMPLATE/*" + - "**/*.md" + +jobs: + build: + runs-on: "ubuntu-latest" + container: "fedora:35" + steps: + - name: "Install git" + shell: bash + run: | + export BUILD_REASON=Schedule + yum install -y git + - name: "Install curl" + shell: bash + run: | + export BUILD_REASON=Schedule + yum install -y curl + - name: "Ensure /run/sshd exists" + shell: bash + run: | + export BUILD_REASON=Schedule + mkdir -p /run/sshd + - name: "Install openssh-server" + shell: bash + run: | + export BUILD_REASON=Schedule + yum install -y openssh-server + - name: "checkout repo" + uses: actions/checkout@v2 + with: + submodules: "recursive" + - name: "Fetch tags" + shell: bash + run: | + export BUILD_REASON=Schedule + git fetch --depth=1 origin +refs/tags/*:refs/tags/* + - name: "Fetch tag/branch history" + shell: bash + run: | + export BUILD_REASON=Schedule + git fetch --prune --unshallow + - name: "Install Rust" + uses: actions-rs/toolchain@v1 + with: + profile: "minimal" + toolchain: "stable" + override: true + components: "rustfmt" + env: + ACTIONS_ALLOW_UNSECURE_COMMANDS: "true" + - name: "Cache cargo" + uses: actions/cache@v2.1.6 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: "fedora35-None-2-${{ runner.os }}-${{ hashFiles('**/Cargo.lock') }}-cargo" + - name: "Install System Deps" + shell: bash + run: | + export BUILD_REASON=Schedule + env PATH=$PATH ./get-deps + - name: "Build (Release mode)" + shell: bash + run: | + export BUILD_REASON=Schedule + cargo build --all --release + - name: "Test (Release mode)" + shell: bash + run: | + export BUILD_REASON=Schedule + cargo test --all --release + - name: "Package" + shell: bash + run: | + export BUILD_REASON=Schedule + bash ci/deploy.sh + - name: "Move RPM" + shell: bash + run: | + export BUILD_REASON=Schedule + mv ~/rpmbuild/RPMS/*/*.rpm wezterm-nightly-fedora35.rpm + - name: "Upload to Nightly Release" + uses: wez/upload-release-assets@releases/v1 + if: github.event.repository.fork == false + with: + files: "wezterm-*.rpm" + release-tag: "nightly" + repo-token: "${{ secrets.GITHUB_TOKEN }}" diff --git a/.github/workflows/gen_fedora35_tag.yml b/.github/workflows/gen_fedora35_tag.yml new file mode 100644 index 000000000..76b234cff --- /dev/null +++ b/.github/workflows/gen_fedora35_tag.yml @@ -0,0 +1,74 @@ +name: fedora35_tag + +on: + push: + tags: + - "20*" + +jobs: + build: + runs-on: "ubuntu-latest" + container: "fedora:35" + steps: + - name: "Install git" + shell: bash + run: "yum install -y git" + - name: "Install curl" + shell: bash + run: "yum install -y curl" + - name: "Ensure /run/sshd exists" + shell: bash + run: "mkdir -p /run/sshd" + - name: "Install openssh-server" + shell: bash + run: "yum install -y openssh-server" + - name: "checkout repo" + uses: actions/checkout@v2 + with: + submodules: "recursive" + - name: "Fetch tags" + shell: bash + run: "git fetch --depth=1 origin +refs/tags/*:refs/tags/*" + - name: "Fetch tag/branch history" + shell: bash + run: "git fetch --prune --unshallow" + - name: "Install Rust" + uses: actions-rs/toolchain@v1 + with: + profile: "minimal" + toolchain: "stable" + override: true + components: "rustfmt" + env: + ACTIONS_ALLOW_UNSECURE_COMMANDS: "true" + - name: "Cache cargo" + uses: actions/cache@v2.1.6 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: "fedora35-None-2-${{ runner.os }}-${{ hashFiles('**/Cargo.lock') }}-cargo" + - name: "Install System Deps" + shell: bash + run: "env PATH=$PATH ./get-deps" + - name: "Build (Release mode)" + shell: bash + run: "cargo build --all --release" + - name: "Test (Release mode)" + shell: bash + run: "cargo test --all --release" + - name: "Package" + shell: bash + run: "bash ci/deploy.sh" + - name: "Move RPM" + shell: bash + run: "mv ~/rpmbuild/RPMS/*/*.rpm ." + - name: "Upload to Tagged Release" + uses: softprops/action-gh-release@v1 + if: github.event.repository.fork == false + with: + files: "wezterm-*.rpm" + prerelease: true + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" diff --git a/ci/generate-workflows.py b/ci/generate-workflows.py index 38d279505..e619de3b9 100755 --- a/ci/generate-workflows.py +++ b/ci/generate-workflows.py @@ -574,6 +574,7 @@ TARGETS = [ # https://fedoraproject.org/wiki/End_of_life?rd=LifeCycle/EOL Target(container="fedora:33"), Target(container="fedora:34"), + Target(container="fedora:35"), Target(container="centos:7", bootstrap_git=True), Target(container="centos:8"), Target(name="windows", os="vs2017-win2016", rust_target="x86_64-pc-windows-msvc"), diff --git a/ci/subst-release-info.py b/ci/subst-release-info.py index 4c632b02a..e98c6b945 100755 --- a/ci/subst-release-info.py +++ b/ci/subst-release-info.py @@ -16,6 +16,8 @@ CATEGORIZE = { r".fedora33.rpm$": "fedora33_rpm", r".fc34.x86_64.rpm$": "fedora34_rpm", r".fedora34.rpm$": "fedora34_rpm", + r".fc35.x86_64.rpm$": "fedora35_rpm", + r".fedora35.rpm$": "fedora35_rpm", r"Debian9.12.deb$": "debian9_deb", r"Debian10.deb$": "debian10_deb", r"Debian11.deb$": "debian11_deb", diff --git a/docs/install/linux.markdown b/docs/install/linux.markdown index 3ddd01898..9065e0286 100644 --- a/docs/install/linux.markdown +++ b/docs/install/linux.markdown @@ -73,12 +73,13 @@ on most Linux systems. |CentOS8 |[{{ centos8_rpm_stable_asset }}]({{ centos8_rpm_stable }}) |[{{ centos8_rpm_nightly_asset }}]({{ centos8_rpm_nightly }})| |Fedora33 |[{{ fedora33_rpm_stable_asset }}]({{ fedora33_rpm_stable }}) |[{{ fedora33_rpm_nightly_asset }}]({{ fedora33_rpm_nightly }})| |Fedora34 |[{{ fedora34_rpm_stable_asset }}]({{ fedora34_rpm_stable }}) |[{{ fedora34_rpm_nightly_asset }}]({{ fedora34_rpm_nightly }})| +|Fedora35 |Nightly builds only|[{{ fedora35_rpm_nightly_asset }}]({{ fedora35_rpm_nightly }})| To download and install from the CLI you can use something like this, which -shows how to install the Fedora 33 package: +shows how to install the Fedora 35 package: ```bash -sudo dnf install -y {{ fedora33_rpm_stable }} +sudo dnf install -y {{ fedora35_rpm_stable }} ``` * The package installs `/usr/bin/wezterm` and `/usr/share/applications/org.wezfurlong.wezterm.desktop`