Skip to content

Commit dbf55a7

Browse files
authored
Merge pull request #17 from sv2dev/16-fix-search-overridden-by-href
2 parents fff2063 + 97c7bdd commit dbf55a7

206 files changed

Lines changed: 1991 additions & 4289 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.circleci/config.yml

Lines changed: 0 additions & 48 deletions
This file was deleted.

.github/workflows/publish.yaml

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
jobs:
8+
check-version:
9+
name: Check if version changed
10+
runs-on: ubuntu-latest
11+
outputs:
12+
core-changed: ${{ steps.check.outputs.core-changed }}
13+
lit-changed: ${{ steps.check.outputs.lit-changed }}
14+
steps:
15+
- uses: actions/checkout@v4
16+
with:
17+
fetch-depth: 2
18+
- name: Check if package.json version changed
19+
id: check
20+
shell: bash
21+
run: |
22+
function get_version() {
23+
local package_path=$1
24+
if [ -f "$package_path" ]; then
25+
jq -r .version "$package_path" || echo "0.0.0"
26+
else
27+
echo "0.0.0"
28+
fi
29+
}
30+
31+
CURRENT_CORE_VERSION=$(get_version "packages/esroute/package.json")
32+
CURRENT_LIT_VERSION=$(get_version "packages/esroute-lit/package.json")
33+
git checkout HEAD^
34+
PREVIOUS_CORE_VERSION=$(get_version "packages/esroute/package.json")
35+
PREVIOUS_LIT_VERSION=$(get_version "packages/esroute-lit/package.json")
36+
37+
core_changed=$([ "$CURRENT_CORE_VERSION" != "$PREVIOUS_CORE_VERSION" ] && echo "true" || echo "false")
38+
lit_changed=$([ "$CURRENT_LIT_VERSION" != "$PREVIOUS_LIT_VERSION" ] && echo "true" || echo "false")
39+
echo "core-changed=$core_changed" >> "$GITHUB_OUTPUT"
40+
echo "lit-changed=$lit_changed" >> "$GITHUB_OUTPUT"
41+
42+
publish-core:
43+
name: Publish core package
44+
needs: check-version
45+
if: needs.check-version.outputs.core-changed == 'true'
46+
runs-on: ubuntu-latest
47+
permissions:
48+
contents: read
49+
id-token: write
50+
steps:
51+
- uses: actions/checkout@v4
52+
- uses: actions/setup-node@v4
53+
with:
54+
node-version: 22
55+
registry-url: "https://registry.npmjs.org"
56+
- run: |
57+
npm install
58+
cd packages/esroute
59+
npm publish
60+
env:
61+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
62+
63+
publish-lit:
64+
name: Publish lit package
65+
needs: check-version
66+
if: needs.check-version.outputs.lit-changed == 'true'
67+
runs-on: ubuntu-latest
68+
permissions:
69+
contents: read
70+
id-token: write
71+
steps:
72+
- uses: actions/checkout@v4
73+
- uses: actions/setup-node@v4
74+
with:
75+
node-version: 22
76+
registry-url: "https://registry.npmjs.org"
77+
- run: |
78+
npm install
79+
cd packages/esroute-lit
80+
npm publish
81+
env:
82+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/test-build.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Test and Build
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
jobs:
8+
test:
9+
name: Run all tests
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- run: npm install
14+
- run: npm run build
15+
- run: npm run test

.gitignore

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
1-
.yarn/*
2-
!.yarn/cache
3-
!.yarn/patches
4-
!.yarn/plugins
5-
!.yarn/releases
6-
!.yarn/sdks
7-
!.yarn/versions
81
node_modules
92
dist
103
demo/demo.js
114
demo/demo.js.map
5+
*.tsbuildinfo
-3.79 MB
Binary file not shown.
-10.3 KB
Binary file not shown.
-3.29 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)