Skip to content

Commit

Permalink
Merge pull request #343 from lando/edge
Browse files Browse the repository at this point in the history
Edge
  • Loading branch information
pirog authored Feb 28, 2025
2 parents 345f666 + ed1f53a commit 2249fa5
Show file tree
Hide file tree
Showing 292 changed files with 4,347 additions and 2,336 deletions.
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ _site
coverage
!.vitepress
config.mjs.timestamp-*.mjs
plugins/*
!plugins/test
17 changes: 15 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
{
"env": {
"node": true,
"mocha": true
"mocha": true,
"es2021": true
},
"parser": "@babel/eslint-parser",
"parserOptions": {
"sourceType": "module",
"ecmaVersion": 8,
"requireConfigFile": false
},
"extends": "google",
"extends": [
"eslint:recommended",
"google"
],
"rules": {
"arrow-parens": ["error",
"as-needed"
Expand All @@ -18,6 +22,15 @@
"code": 140,
"ignoreComments": true
}],
"no-empty": ["error", {
"allowEmptyCatch": true
}],
"no-unused-vars": ["error", {
"vars": "all",
"args": "after-used",
"ignoreRestSiblings": false
}],

"require-jsdoc": ["error", {
"require": {
"FunctionDeclaration": true,
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/deploy-npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,14 @@ jobs:
fi
env:
NODE_AUTH_TOKEN: ${{ secrets.npm-token }}
- name: Update edge release alias on main
if: github.event.release.target_commitish == 'edge'
run: |
git clone https://github.com/lando/core.git core
cd core
git config user.name "rtfm-47"
git config user.email "[email protected]"
echo "${{ github.event.release.tag_name }}" > ./release-aliases/3-EDGE
git add .
git commit -m "Update edge release alias to ${{ github.event.release.tag_name }} triggered by @rtfm-47"
git push https://x-access-token:${{ secrets.github-token }}@github.com/lando/core.git main
30 changes: 8 additions & 22 deletions .github/workflows/dev-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- main
- edge
- 'preview-**'

jobs:
Expand All @@ -19,14 +20,11 @@ jobs:
- linux
- macos
- win
fatcore:
- false
- true

with:
arch: ${{ matrix.arch }}
edge: true
fatcore: ${{ matrix.fatcore }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.fatcore == false && '-slim' || '' }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}
node-version: "20"
os: ${{ matrix.os }}
version: dev
Expand All @@ -47,13 +45,6 @@ jobs:
- lando-macos-x64-${{ github.sha }}
- lando-win-x64-${{ github.sha }}

- lando-linux-arm64-${{ github.sha }}-slim
- lando-macos-arm64-${{ github.sha }}-slim
- lando-win-arm64-${{ github.sha }}-slim

- lando-linux-x64-${{ github.sha }}-slim
- lando-macos-x64-${{ github.sha }}-slim
- lando-win-x64-${{ github.sha }}-slim
with:
download-pattern: packaged-lando-*
file: ${{ matrix.file }}
Expand All @@ -80,15 +71,12 @@ jobs:
- linux
- macos
- win
type:
- -slim
-
alias:
- dev
- latest
with:
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}${{ matrix.type }}
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}
download-pattern: signed-lando-*
build-release-binary-branch:
uses: ./.github/workflows/release-rename-binary.yml
Expand All @@ -104,12 +92,10 @@ jobs:
- linux
- macos
- win
type:
- -slim
-

with:
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}${{ matrix.type }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.head_ref || github.ref_name }}${{ matrix.type }}
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.head_ref || github.ref_name }}
download-pattern: signed-lando-*

checksum:
Expand Down
21 changes: 6 additions & 15 deletions .github/workflows/pkg-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,6 @@ on:
description: The name of the resulting binary
required: false
type: string
fatcore:
default: false
description: Whether to build a fat binary or not
required: false
type: boolean
node-version:
default: "20"
description: The node version to build for eg 16 | 18 | 20
Expand Down Expand Up @@ -56,9 +51,8 @@ jobs:
cache: npm
- name: Install dependencies
run: npm clean-install --prefer-offline --frozen-lockfile --production
- name: Install fatcore
if: inputs.fatcore == true
run: scripts/fatcore-install.sh ${{ inputs.edge == true && '--edge' || '' }}
- name: Install plugins
run: scripts/install-plugins.sh --lando bin/lando ${{ inputs.edge == true && '--edge' || '' }}
- name: Switch to edge channel
if: inputs.edge == true
run: |
Expand All @@ -78,7 +72,7 @@ jobs:
os: ${{ inputs.os }}
options: --options dns-result-order=ipv4first
pkg: "@yao-pkg/[email protected]"
upload-key: "packaged-${{ inputs.filename }}-${{ inputs.os }}-${{ inputs.arch }}${{ inputs.fatcore == false && '-slim' || '' }}-${{ github.sha }}"
upload-key: "packaged-${{ inputs.filename }}-${{ inputs.os }}-${{ inputs.arch }}-${{ github.sha }}"
- name: Ensure version
if: (inputs.os == 'linux' && runner.os == 'Linux') || (inputs.os == 'macos' && runner.os == 'macOS')
run: ./dist/${{ inputs.filename }} version --all
Expand All @@ -88,11 +82,8 @@ jobs:
- name: Ensure channel
if: (inputs.os == 'linux' && runner.os == 'Linux') || (inputs.os == 'macos' && runner.os == 'macOS')
run: ./dist/${{ inputs.filename }} config --path channel | grep ${{ inputs.edge == true && 'edge' || 'stable' }}
- name: Ensure slimcore
if: ((inputs.os == 'linux' && runner.os == 'Linux') || (inputs.os == 'macos' && runner.os == 'macOS')) && inputs.fatcore == false
run: ./dist/${{ inputs.filename }} config --path fatcore | grep false
- name: Ensure fatcore
if: ((inputs.os == 'linux' && runner.os == 'Linux') || (inputs.os == 'macos' && runner.os == 'macOS')) && inputs.fatcore == true
- name: Ensure plugin install
if: ((inputs.os == 'linux' && runner.os == 'Linux') || (inputs.os == 'macos' && runner.os == 'macOS'))
run: |
./dist/${{ inputs.filename }} config --path fatcore | grep true
./dist/${{ inputs.filename }} config | grep -q "node_modules/@lando/wordpress"
./dist/${{ inputs.filename }} config | grep -q "/snapshot/core/plugins/wordpress"
7 changes: 4 additions & 3 deletions .github/workflows/pr-core-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,11 @@ jobs:
- c,o,m,m,a
- cache
- certs
- command
- config
- debug
- envfile
- entrypoint
# - environment
- events
- exec
Expand Down Expand Up @@ -58,18 +60,16 @@ jobs:
- tooling
- update
- version
- yaml
node-version:
- "20"
os:
# - macos-13
# - macos-14
- ubuntu-24.04
# - windows-2022
shell:
- bash

# TODO: includes for also running windows tests on cmd/powershell?

steps:
- name: Checkout code
uses: actions/checkout@v4
Expand Down Expand Up @@ -98,6 +98,7 @@ jobs:
id: pkg-action
with:
entrypoint: bin/lando
filename: lando
node-version: ${{ matrix.node-version }}
options: --options dns-result-order=ipv4first
upload: false
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr-docs-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ jobs:
id: pkg-action
with:
entrypoint: bin/lando
filename: lando
node-version: ${{ matrix.node-version }}
options: --options dns-result-order=ipv4first
upload: false
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr-release-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- win
with:
arch: ${{ matrix.arch }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-slim-${{ github.sha }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.sha }}
node-version: "20"
os: ${{ matrix.os }}
version: dev
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr-setup-linux-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
id: pkg-action
with:
entrypoint: bin/lando
filename: lando
node-version: ${{ matrix.node-version }}
options: --options dns-result-order=ipv4first
upload: false
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr-setup-macos-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
id: pkg-action
with:
entrypoint: bin/lando
filename: lando
node-version: ${{ matrix.node-version }}
options: --options dns-result-order=ipv4first
upload: false
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr-setup-windows-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ jobs:
id: pkg-action
with:
entrypoint: bin/lando
filename: lando
node-version: ${{ matrix.node-version }}
options: --options dns-result-order=ipv4first
upload: false
Expand Down
28 changes: 6 additions & 22 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,11 @@ jobs:
- linux
- macos
- win
fatcore:
- false
- true

with:
arch: ${{ matrix.arch }}
edge: ${{ github.event.release.prerelease }}
fatcore: ${{ matrix.fatcore }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.fatcore == false && '-slim' || '' }}
filename: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}
node-version: "20"
os: ${{ matrix.os }}
version: ${{ github.event.release.tag_name }}
Expand All @@ -46,13 +43,6 @@ jobs:
- lando-macos-x64-${{ github.ref_name }}
- lando-win-x64-${{ github.ref_name }}

- lando-linux-arm64-${{ github.ref_name }}-slim
- lando-macos-arm64-${{ github.ref_name }}-slim
- lando-win-arm64-${{ github.ref_name }}-slim

- lando-linux-x64-${{ github.ref_name }}-slim
- lando-macos-x64-${{ github.ref_name }}-slim
- lando-win-x64-${{ github.ref_name }}-slim
with:
download-pattern: packaged-lando-*
file: ${{ matrix.file }}
Expand All @@ -79,14 +69,11 @@ jobs:
- linux
- macos
- win
type:
- -slim
-
alias: ${{ github.event.release.prerelease == true && fromJson('["edge"]') || fromJson('["stable", "edge"]') }}

with:
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.type }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}${{ matrix.type }}
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.alias }}
download-pattern: signed-lando-*
build-release-binary-tag:
uses: ./.github/workflows/release-rename-binary.yml
Expand All @@ -102,12 +89,9 @@ jobs:
- linux
- macos
- win
type:
- -slim
-
with:
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.type }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}${{ matrix.type }}
source: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}
destination: lando-${{ matrix.os }}-${{ matrix.arch }}-${{ github.ref_name }}
download-pattern: signed-lando-*

checksum:
Expand Down
7 changes: 1 addition & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,8 @@ coverage/
.lando/id
checksums.txt
plugins/*
!plugins/healthcheck
!plugins/networking
!plugins/proxy
!plugins/scanner
!plugins/sharing
!plugins/test
FATCORE
!plugins/.gitkeep

# docs
.temp
Expand Down
Loading

0 comments on commit 2249fa5

Please sign in to comment.