mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2024-11-11 01:28:17 +03:00
Merge commit '51c6590cf53580b1ae5f904e96973e594e8680e3' into checkpoint/long_lived_atari_from_main_51c6590cf53580b1ae5f904e96973e594e8680e3
This commit is contained in:
commit
9c5d2a1a06
36
.github/actions/install/action.yml
vendored
Normal file
36
.github/actions/install/action.yml
vendored
Normal file
@ -0,0 +1,36 @@
|
||||
name: "Install chia-blockchain"
|
||||
|
||||
description: "Run the platform appropriate installer script."
|
||||
|
||||
inputs:
|
||||
python-version:
|
||||
description: "Value to be set for INSTALL_PYTHON_VERSION."
|
||||
required: false
|
||||
default: ""
|
||||
development:
|
||||
description: "Install development dependencies."
|
||||
required: false
|
||||
default: ""
|
||||
command-prefix:
|
||||
description: "Text to place before the command such as `arch -arm64` for non-native macOS runners."
|
||||
required: false
|
||||
default: ""
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Run install script (macOS, Ubuntu)
|
||||
if: runner.os == 'macos' || runner.os == 'linux'
|
||||
shell: bash
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ inputs.python-version }}
|
||||
run: |
|
||||
${{ inputs.command-prefix }} sh install.sh ${{ inputs.development && '-d' || '' }}
|
||||
|
||||
- name: Run install script (Windows)
|
||||
if: runner.os == 'windows'
|
||||
shell: pwsh
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ inputs.python-version }}
|
||||
run: |
|
||||
${{ inputs.command-prefix }} ./Install.ps1 ${{ inputs.development && '-d' || '' }}
|
14
.github/workflows/benchmarks.yml
vendored
14
.github/workflows/benchmarks.yml
vendored
@ -66,13 +66,13 @@ jobs:
|
||||
ref: ${{ env.BLOCKS_AND_PLOTS_VERSION }}
|
||||
fetch-depth: 1
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: pytest
|
||||
run: |
|
||||
. ./activate
|
||||
./venv/bin/py.test -n 0 --capture no -m benchmark tests
|
||||
pytest -n 0 --capture no -m benchmark tests
|
||||
|
@ -107,11 +107,12 @@ jobs:
|
||||
tar -xvzf /tmp/bladebit.tar.gz -C $GITHUB_WORKSPACE/bladebit
|
||||
chmod +x "$GITHUB_WORKSPACE/bladebit/bladebit"
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Build arm64 .deb package
|
||||
env:
|
||||
@ -119,7 +120,6 @@ jobs:
|
||||
run: |
|
||||
ldd --version
|
||||
git -C ./chia-blockchain-gui status
|
||||
. ./activate
|
||||
cd ./build_scripts
|
||||
sh build_linux_deb.sh arm64
|
||||
|
||||
|
12
.github/workflows/build-linux-installer-deb.yml
vendored
12
.github/workflows/build-linux-installer-deb.yml
vendored
@ -138,11 +138,12 @@ jobs:
|
||||
tar -xvzf /tmp/bladebit.tar.gz -C $GITHUB_WORKSPACE/bladebit
|
||||
chmod +x "$GITHUB_WORKSPACE/bladebit/bladebit"
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Setup Node 16.x
|
||||
uses: actions/setup-node@v3
|
||||
@ -159,7 +160,6 @@ jobs:
|
||||
run: |
|
||||
ldd --version
|
||||
git -C ./chia-blockchain-gui status
|
||||
. ./activate
|
||||
cd ./build_scripts
|
||||
sh build_linux_deb.sh amd64
|
||||
|
||||
|
12
.github/workflows/build-linux-installer-rpm.yml
vendored
12
.github/workflows/build-linux-installer-rpm.yml
vendored
@ -107,11 +107,12 @@ jobs:
|
||||
tar -xvzf /tmp/bladebit.tar.gz -C $GITHUB_WORKSPACE/bladebit
|
||||
chmod +x "$GITHUB_WORKSPACE/bladebit/bladebit"
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Build .rpm package
|
||||
env:
|
||||
@ -119,7 +120,6 @@ jobs:
|
||||
run: |
|
||||
ldd --version
|
||||
git -C ./chia-blockchain-gui status
|
||||
. ./activate
|
||||
cd ./build_scripts
|
||||
bash build_linux_rpm.sh amd64
|
||||
|
||||
|
12
.github/workflows/build-macos-installer.yml
vendored
12
.github/workflows/build-macos-installer.yml
vendored
@ -126,11 +126,12 @@ jobs:
|
||||
chmod +x "$GITHUB_WORKSPACE/madmax/chia_plot"
|
||||
chmod +x "$GITHUB_WORKSPACE/madmax/chia_plot_k34"
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Setup Node 16.x
|
||||
uses: actions/setup-node@v3
|
||||
@ -145,7 +146,6 @@ jobs:
|
||||
APPLE_NOTARIZE_PASSWORD: "${{ secrets.APPLE_NOTARIZE_PASSWORD }}"
|
||||
run: |
|
||||
git -C ./chia-blockchain-gui status
|
||||
. ./activate
|
||||
cd ./build_scripts
|
||||
sh build_macos.sh
|
||||
|
||||
|
13
.github/workflows/build-macos-m1-installer.yml
vendored
13
.github/workflows/build-macos-m1-installer.yml
vendored
@ -100,11 +100,13 @@ jobs:
|
||||
chmod +x "$GITHUB_WORKSPACE/madmax/chia_plot"
|
||||
chmod +x "$GITHUB_WORKSPACE/madmax/chia_plot_k34"
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: |
|
||||
arch -arm64 sh install.sh -d
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
command-prefix: "arch -arm64"
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Install node 16.x
|
||||
run: |
|
||||
@ -119,7 +121,6 @@ jobs:
|
||||
run: |
|
||||
export PATH=$(brew --prefix node@16)/bin:$PATH
|
||||
git -C ./chia-blockchain-gui status
|
||||
. ./activate
|
||||
cd ./build_scripts
|
||||
arch -arm64 sh build_macos_m1.sh
|
||||
|
||||
|
9
.github/workflows/pre-commit.yml
vendored
9
.github/workflows/pre-commit.yml
vendored
@ -19,8 +19,11 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- uses: actions/setup-python@v3
|
||||
- name: Run install script
|
||||
run: |
|
||||
sh install.sh -d
|
||||
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
development: true
|
||||
|
||||
- uses: pre-commit/action@v2.0.3
|
||||
|
22
.github/workflows/test-install-scripts.yml
vendored
22
.github/workflows/test-install-scripts.yml
vendored
@ -39,14 +39,15 @@ jobs:
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: sh install.sh
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Run install-gui script
|
||||
run: |
|
||||
. ./activate
|
||||
sh install-gui.sh
|
||||
|
||||
test_scripts_in_docker:
|
||||
@ -239,12 +240,13 @@ jobs:
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Run install script
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
||||
run: sh install.sh -a
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
development: true
|
||||
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Run chia --help
|
||||
run: |
|
||||
. ./activate
|
||||
chia --help
|
||||
|
22
.github/workflows/test-single.yml
vendored
22
.github/workflows/test-single.yml
vendored
@ -174,24 +174,12 @@ jobs:
|
||||
run: |
|
||||
brew install boost
|
||||
|
||||
- name: Run install script (macOS, Ubuntu)
|
||||
if: matrix.os.matrix == 'macos' || matrix.os.matrix == 'ubuntu'
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python.install_sh }}
|
||||
run: |
|
||||
sh install.sh -d
|
||||
echo "$(cd venv/bin/; pwd)" >> $GITHUB_PATH
|
||||
echo "VIRTUAL_ENV=$(cd venv/; pwd)" >> $GITHUB_ENV
|
||||
- uses: ./.github/actions/install
|
||||
with:
|
||||
python-version: ${{ matrix.python.install_sh }}
|
||||
development: true
|
||||
|
||||
- name: Run install script (Windows)
|
||||
if: matrix.os.matrix == 'windows'
|
||||
env:
|
||||
INSTALL_PYTHON_VERSION: ${{ matrix.python.install_sh }}
|
||||
run: |
|
||||
./Install.ps1 -d
|
||||
(Resolve-Path venv/Scripts/).Path >> $Env:GITHUB_PATH
|
||||
$env_path = (Resolve-Path venv/).Path
|
||||
Write-Output "VIRTUAL_ENV=$env_path" >> $Env:GITHUB_ENV
|
||||
- uses: chia-network/actions/activate-venv@main
|
||||
|
||||
- name: Install timelord
|
||||
if: matrix.configuration.install_timelord
|
||||
|
@ -44,7 +44,7 @@ if ($null -eq (Get-Command py -ErrorAction SilentlyContinue))
|
||||
}
|
||||
|
||||
$supportedPythonVersions = "3.10", "3.9", "3.8", "3.7"
|
||||
if (Test-Path env:INSTALL_PYTHON_VERSION)
|
||||
if ("$env:INSTALL_PYTHON_VERSION" -ne "")
|
||||
{
|
||||
$pythonVersion = $env:INSTALL_PYTHON_VERSION
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user