-
Notifications
You must be signed in to change notification settings - Fork 824
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test Initial styles Ranges support Comments Done Fix type errors Add comments Fix Do not load polyfill in chrome Support range units not defined in polyfill patch polyfill Add progress and closest examples Fix Add elephants Add submodules Add branch Test Test dd Test private checkout Try SSH Test animate branch in submodule Test local action Check Use submodules sh Fix name Fix Check it fails Test env Check again Test workflow call from env fix Test Fix Test Pass secret hack Pass env as input too Add comments etc Check submodules Test Check Improve Move from the main repo
- Loading branch information
Showing
24 changed files
with
581 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: CI setup | ||
|
||
description: | | ||
Sets up the CI environment for the project. | ||
inputs: | ||
submodules-ssh-key: | ||
description: "The SSH key to private submodules to use for the checkout" | ||
required: true | ||
|
||
runs: | ||
using: "composite" | ||
|
||
steps: | ||
- name: Set up SSH for Git | ||
if: ${{ inputs.submodules-ssh-key }} | ||
run: | | ||
mkdir -p ~/.ssh | ||
echo "${{ inputs.submodules-ssh-key }}" > ~/.ssh/id_ed25519 | ||
chmod 600 ~/.ssh/id_ed25519 | ||
ssh-keyscan github.com >> ~/.ssh/known_hosts | ||
shell: bash | ||
|
||
- name: Verify SSH Connection (Optional) | ||
if: ${{ inputs.submodules-ssh-key }} | ||
run: | | ||
ssh -T [email protected] || true | ||
shell: bash | ||
|
||
- name: Verify SSH Connection (Optional) | ||
if: ${{ inputs.submodules-ssh-key }} | ||
run: | | ||
echo Branch is ${{ github.event.pull_request.head.ref || github.ref_name }} | ||
shell: bash | ||
|
||
- name: Try checkout submodules to the same branch as main repo | ||
if: ${{ inputs.submodules-ssh-key }} | ||
run: | | ||
./submodules.sh ${{ github.event.pull_request.head.ref || github.ref_name }} | ||
shell: bash | ||
|
||
- name: Show main readme | ||
if: ${{ inputs.submodules-ssh-key }} | ||
run: | | ||
cat ./packages/sdk-components-animation/private-src/README.md || echo "No README found" | ||
shell: bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: Check submodules | ||
|
||
on: | ||
pull_request: | ||
|
||
# cancel in-progress runs on new commits to same PR (gitub.event.number) | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.number || github.sha }} | ||
cancel-in-progress: true | ||
|
||
permissions: | ||
contents: read # to fetch code (actions/checkout) | ||
|
||
jobs: | ||
checks: | ||
timeout-minutes: 20 | ||
|
||
environment: | ||
name: development | ||
|
||
env: | ||
DATABASE_URL: postgres:// | ||
AUTH_SECRET: test | ||
|
||
runs-on: ubuntu-24.04-arm | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.pull_request.head.sha || github.sha }} | ||
|
||
- uses: ./.github/actions/submodules-checkout | ||
with: | ||
submodules-ssh-key: ${{ secrets.PRIVATE_GITHUB_DEPLOY_TOKEN }} | ||
|
||
- name: Check if any submodule branch matches github.ref_name | ||
run: | | ||
echo "C ${{ github.workflow }}-${{ github.event.number || github.sha }}" | ||
# Get the current branch or tag name | ||
REF_NAME="${{ github.event.pull_request.head.ref || github.ref_name }}" | ||
echo "Branch is:" $REF_NAME | ||
# List all submodule paths | ||
SUBMODULES=$(git submodule status | awk '{print $2}') | ||
# Check each submodule's branch | ||
for SUBMODULE in $SUBMODULES; do | ||
echo "Checking submodule: $SUBMODULE" | ||
( | ||
cd "$SUBMODULE" | ||
# Get the current branch of the submodule | ||
SUBMODULE_BRANCH=$(git rev-parse --abbrev-ref HEAD) | ||
echo "Submodule branch: $SUBMODULE_BRANCH" | ||
# Compare the submodule branch to the ref_name | ||
if [ "$SUBMODULE_BRANCH" = "$REF_NAME" ]; then | ||
echo "::error::Submodule '$SUBMODULE' is on branch '$SUBMODULE_BRANCH', which matches the current ref '$REF_NAME'." | ||
exit 1 | ||
fi | ||
) | ||
if [ $? -ne 0 ]; then | ||
exit 1 # Fail the workflow if any submodule branch matches | ||
fi | ||
done | ||
echo "No submodule is on the same branch as the current ref '$REF_NAME'." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
[submodule "packages/sdk-components-animation/private-src"] | ||
path = packages/sdk-components-animation/private-src | ||
url = [email protected]:webstudio-is/sdk-components-animation.git | ||
branch = main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
type ScrollAxis = "block" | "inline" | "x" | "y"; | ||
|
||
interface ScrollTimelineOptions { | ||
source?: Element | Document | null; | ||
axis?: ScrollAxis; | ||
} | ||
|
||
declare class ScrollTimeline extends AnimationTimeline { | ||
constructor(options?: ScrollTimelineOptions); | ||
} | ||
|
||
declare class ViewTimeline extends ScrollTimeline { | ||
constructor(options?: ScrollTimelineOptions); | ||
} |
Oops, something went wrong.