Skip to content

Commit 284eb46

Browse files
committed
feat: sync infrastructure changes from develop to main
This PR contains minimal infrastructure updates required to align main branch with develop branch improvements: Changes from commit e0c152e (release tag pattern fix): - Add endsWith() checks to release tag matching logic - Ensures tags ending with '-ats' or '-ATS' trigger workflows - Fixes both contracts and SDK job conditions in ats.publish.yml Changes from commit 7f34000 (npm publish access fix): - Change npm publish access from 'restricted' to 'public' - Required for scoped @hashgraph packages to publish correctly - Applied to both contracts and SDK publish steps Additional change: - Move workflows documentation from .github/README.md to .github/workflows/README.md for better organization All other workflow files remain identical to main branch, ensuring no unintended regressions. This is part 1/2 of the develop-to-main sync strategy (infrastructure changes only). Related: Part 2/2 is PR #713 (codebase changes) Signed-off-by: Miguel_LZPF <miguel.carpena@io.builders>
1 parent 82f334a commit 284eb46

File tree

2 files changed

+13
-37
lines changed

2 files changed

+13
-37
lines changed
Lines changed: 7 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -11,28 +11,6 @@ The repository uses **Changesets** for version management with independent relea
1111

1212
All development happens on the `develop` branch with automated testing, changeset validation, and manual release controls by authorized teams.
1313

14-
## How to test github workflows locally
15-
16-
To be able to test github workflows locally you can use act, a github actions simulator [act homepage](https://nektosact.com/introduction.html)
17-
18-
### Install act
19-
20-
```bash
21-
curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/nektos/act/master/install.sh | sudo bash
22-
```
23-
24-
### Run workflow
25-
26-
Substitute \<workflow\> for the workflow you want to test (ats.pubilsh, mp.release, ...)
27-
28-
```bash
29-
./bin/act workflow_dispatch \
30-
-W .github/workflows/<workflow>.yml \
31-
--input dry-run-enabled=true \
32-
-s NPM_TOKEN=fake_token \
33-
-P token-studio-linux-large=catthehacker/ubuntu:act-latest
34-
```
35-
3614
## Developer Workflow
3715

3816
### Daily Development Process
@@ -80,13 +58,11 @@ sequenceDiagram
8058

8159
4. **Commit with DCO and Signature compliance**:
8260

83-
Commit messages should comply with the [conventional commits standard](https://www.conventionalcommits.org/en/v1.0.0/)
84-
85-
```bash
86-
git add .
87-
git commit --signoff -S -m "feat: your commit message"
88-
git push origin feature/your-feature-name
89-
```
61+
```bash
62+
git add .
63+
git commit --signoff -S -m "feat: your commit message"
64+
git push origin feature/your-feature-name
65+
```
9066

9167
5. **Open PR to develop branch** - automated checks will run
9268

@@ -340,13 +316,13 @@ sequenceDiagram
340316

341317
```bash
342318
# Development
343-
npm run changeset # Create changeset
319+
npm run changeset # Create changeset
344320
npm run changeset:status # Check pending changes
345321
npm run ats:test # Run ATS tests
346322
npm run mass-payout:test # Run MP tests
347323

348324
# Preview releases
349-
npm run release:preview # Show all pending releases
325+
npm run release:preview # Show all pending releases
350326
npm run release:ats # Preview ATS release (local)
351327
npm run release:mp # Preview MP release (local)
352328
```

.github/workflows/ats.publish.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ jobs:
2727
contracts:
2828
name: Publish ATS Contracts
2929
runs-on: token-studio-linux-large
30-
# Only run if manual trigger OR release tag contains '-ats-'/'-ATS-'
31-
if: ${{ github.event_name == 'workflow_dispatch' || contains(github.ref_name, '-ats-') || contains(github.ref_name, '-ATS-') }}
30+
# Only run if manual trigger OR release tag contains/ends with '-ats'/'-ATS'
31+
if: ${{ github.event_name == 'workflow_dispatch' || contains(github.ref_name, '-ats-') || contains(github.ref_name, '-ATS-') || endsWith(github.ref_name, '-ats') || endsWith(github.ref_name, '-ATS') }}
3232

3333
steps:
3434
- name: Harden Runner
@@ -67,7 +67,7 @@ jobs:
6767
DRY_RUN: ${{ inputs.dry-run-enabled }}
6868
working-directory: packages/ats/contracts
6969
run: |
70-
PUBLISH_ARGS=("--access=restricted")
70+
PUBLISH_ARGS=("--access=public")
7171
if [[ "${DRY_RUN}" == "true" ]]; then
7272
PUBLISH_ARGS+=("--dry-run")
7373
echo "🔍 DRY RUN MODE: Would publish @hashgraph/asset-tokenization-contracts"
@@ -82,8 +82,8 @@ jobs:
8282
sdk:
8383
name: Publish ATS SDK
8484
runs-on: token-studio-linux-large
85-
# Only run if manual trigger OR release tag contains '-ats-'/'-ATS-'
86-
if: ${{ github.event_name == 'workflow_dispatch' || contains(github.ref_name, '-ats-') || contains(github.ref_name, '-ATS-') }}
85+
# Only run if manual trigger OR release tag contains/ends with '-ats'/'-ATS'
86+
if: ${{ github.event_name == 'workflow_dispatch' || contains(github.ref_name, '-ats-') || contains(github.ref_name, '-ATS-') || endsWith(github.ref_name, '-ats') || endsWith(github.ref_name, '-ATS') }}
8787
# needs: contracts # Commented out for parallel execution
8888

8989
steps:
@@ -125,7 +125,7 @@ jobs:
125125
DRY_RUN: ${{ inputs.dry-run-enabled }}
126126
working-directory: packages/ats/sdk
127127
run: |
128-
PUBLISH_ARGS=("--access=restricted")
128+
PUBLISH_ARGS=("--access=public")
129129
if [[ "${DRY_RUN}" == "true" ]]; then
130130
PUBLISH_ARGS+=("--dry-run")
131131
echo "🔍 DRY RUN MODE: Would publish @hashgraph/asset-tokenization-sdk"

0 commit comments

Comments
 (0)