Skip to content

Commit 95c5bb7

Browse files
luigi-iothemariofranciajaime-iobermudezAlbertoMolinaIoBuildersMiguelLZPF
authored
feat: release ATS v4.1.0 and MP v1.0.1 (#818)
Signed-off-by: Mario Francia <mariofranciarius@gmail.com> Signed-off-by: jaime-iobermudez <jaime.bermudez@io.builders> Signed-off-by: Alberto Molina <alberto@io.builders> Signed-off-by: Miguel_LZPF <miguel.carpena@io.builders> Signed-off-by: Miguel Carpena <miguel.carpena@io.builders> Signed-off-by: Luigi Navarro <luigi@io.builders> Co-authored-by: Mario Francia <mariofranciarius@gmail.com> Co-authored-by: jaime-iobermudez <jaime.bermudez@io.builders> Co-authored-by: Alberto Molina <alberto@io.builders> Co-authored-by: Miguel_LZPF <miguel.carpena@io.builders>
1 parent b894381 commit 95c5bb7

File tree

2,626 files changed

+48406
-540353
lines changed

Some content is hidden

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

2,626 files changed

+48406
-540353
lines changed

.github/dependabot.yaml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
version: 2
22
updates:
3-
- package-ecosystem: 'github-actions'
4-
directory: '/'
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
55
schedule:
6-
interval: 'daily'
6+
interval: "daily"
77
open-pull-requests-limit: 10
88
- package-ecosystem: npm
9-
directory: '/'
9+
directory: "/"
1010
schedule:
11-
interval: 'weekly'
11+
interval: "weekly"
1212
open-pull-requests-limit: 10
1313
versioning-strategy: increase
1414
ignore:
1515
# For all packages, ignore all minor & patch updates
16-
- dependency-name: '*'
17-
update-types:
18-
['version-update:semver-minor', 'version-update:semver-patch']
16+
- dependency-name: "*"
17+
update-types: ["version-update:semver-minor", "version-update:semver-patch"]

.github/scripts/setup-git.sh

Lines changed: 255 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,255 @@
1+
#!/bin/bash
2+
3+
###############################################################################
4+
# Git Configuration Setup for Asset Tokenization Studio
5+
#
6+
# This script configures Git to automatically:
7+
# - Add DCO sign-off to all commits (Signed-off-by line)
8+
# - Sign all commits with GPG (cryptographic signature)
9+
# - Use YOUR identity (reads from existing git config)
10+
#
11+
# Usage: bash .github/scripts/setup-git.sh
12+
###############################################################################
13+
14+
set -euo pipefail
15+
16+
echo "🔧 Setting up Git configuration for Asset Tokenization Studio..."
17+
echo ""
18+
19+
# Colors for output
20+
readonly GREEN='\033[0;32m'
21+
readonly YELLOW='\033[1;33m'
22+
readonly RED='\033[0;31m'
23+
readonly BLUE='\033[0;34m'
24+
readonly NC='\033[0m' # No Color
25+
26+
###############################################################################
27+
# Step 1: Verify Author Identity (SECURITY CRITICAL)
28+
###############################################################################
29+
30+
echo "📝 Step 1: Verifying your Git identity..."
31+
echo ""
32+
33+
# Get current git config
34+
CURRENT_NAME=$(git config user.name || echo "")
35+
CURRENT_EMAIL=$(git config user.email || echo "")
36+
37+
if [[ -z "${CURRENT_NAME}" ]] || [[ -z "${CURRENT_EMAIL}" ]]; then
38+
echo -e "${RED}❌ Git identity not configured${NC}"
39+
echo ""
40+
echo "You must configure your identity before proceeding:"
41+
echo ""
42+
echo "Run these commands with YOUR information:"
43+
echo " git config user.name \"Your Name\""
44+
echo " git config user.email \"your.email@example.com\""
45+
echo ""
46+
echo "For global configuration (recommended):"
47+
echo " git config --global user.name \"Your Name\""
48+
echo " git config --global user.email \"your.email@example.com\""
49+
echo ""
50+
echo -e "${YELLOW}⚠️ SECURITY: Never use another developer's identity${NC}"
51+
echo " Each developer must commit with their own name and email"
52+
echo ""
53+
exit 1
54+
fi
55+
56+
echo -e "${GREEN}✅ Current Git identity:${NC}"
57+
echo " Name: ${CURRENT_NAME}"
58+
echo " Email: ${CURRENT_EMAIL}"
59+
echo ""
60+
61+
# Confirm identity
62+
echo -e "${YELLOW}⚠️ Important: Commits will be signed with this identity${NC}"
63+
read -p "Is this correct? (y/N): " -n 1 -r
64+
echo
65+
if [[ ! "${REPLY}" =~ ^[Yy]$ ]]; then
66+
echo ""
67+
echo "Please update your Git identity first:"
68+
echo " git config user.name \"Your Name\""
69+
echo " git config user.email \"your.email@example.com\""
70+
echo ""
71+
exit 1
72+
fi
73+
74+
readonly AUTHOR_NAME="${CURRENT_NAME}"
75+
readonly AUTHOR_EMAIL="${CURRENT_EMAIL}"
76+
77+
echo ""
78+
79+
###############################################################################
80+
# Step 2: Enable Automatic DCO Sign-off
81+
###############################################################################
82+
83+
echo "📝 Step 2: Enabling automatic DCO sign-off..."
84+
echo ""
85+
86+
git config format.signoff true
87+
88+
echo -e "${GREEN}✅ DCO sign-off enabled${NC}"
89+
echo " All commits will automatically include:"
90+
echo " Signed-off-by: ${AUTHOR_NAME} <${AUTHOR_EMAIL}>"
91+
echo ""
92+
93+
###############################################################################
94+
# Step 3: Enable GPG Signing
95+
###############################################################################
96+
97+
echo "📝 Step 3: Enabling GPG commit signing..."
98+
echo ""
99+
100+
# Check if GPG is available
101+
if ! command -v gpg &>/dev/null; then
102+
echo -e "${RED}❌ GPG not found${NC}"
103+
echo ""
104+
echo "Please install GPG:"
105+
echo " - macOS: brew install gnupg"
106+
echo " - Linux: apt-get install gnupg (or yum install gnupg)"
107+
echo " - Windows: https://www.gnupg.org/download/"
108+
echo ""
109+
exit 1
110+
fi
111+
112+
# Check if user has GPG keys
113+
GPG_KEYS=$(gpg --list-secret-keys --keyid-format=long 2>/dev/null | grep ^sec || true)
114+
115+
if [[ -z "${GPG_KEYS}" ]]; then
116+
echo -e "${YELLOW}⚠️ No GPG keys found${NC}"
117+
echo ""
118+
echo "You need to create a GPG key for signing commits."
119+
echo ""
120+
echo -e "${BLUE}Steps to generate a GPG key:${NC}"
121+
echo " 1. Run: gpg --full-generate-key"
122+
echo " 2. Choose: RSA and RSA (default)"
123+
echo " 3. Key size: 4096 bits"
124+
echo " 4. Expiration: 0 (does not expire) or 2y (2 years)"
125+
echo " 5. Real name: ${AUTHOR_NAME}"
126+
echo " 6. Email: ${AUTHOR_EMAIL}"
127+
echo " 7. Enter a passphrase (store it safely!)"
128+
echo ""
129+
130+
read -p "Would you like to generate a GPG key now? (y/N): " -n 1 -r
131+
echo
132+
if [[ "${REPLY}" =~ ^[Yy]$ ]]; then
133+
echo ""
134+
echo "Launching GPG key generation wizard..."
135+
echo ""
136+
gpg --full-generate-key
137+
echo ""
138+
echo -e "${GREEN}✅ GPG key generated${NC}"
139+
GPG_KEYS=$(gpg --list-secret-keys --keyid-format=long 2>/dev/null | grep ^sec)
140+
else
141+
echo ""
142+
echo "Skipping GPG signing configuration."
143+
echo "To enable GPG signing later:"
144+
echo " 1. Generate key: gpg --full-generate-key"
145+
echo " 2. Run this script again: bash .github/scripts/setup-git.sh"
146+
echo ""
147+
exit 0
148+
fi
149+
fi
150+
151+
# Get the GPG key ID for the user's email
152+
GPG_KEY_ID=$(gpg --list-secret-keys --keyid-format=long "${AUTHOR_EMAIL}" 2>/dev/null | grep ^sec | head -1 | cut -d'/' -f2 | cut -d' ' -f1 || true)
153+
154+
if [[ -z "${GPG_KEY_ID}" ]]; then
155+
echo -e "${YELLOW}⚠️ No GPG key found for email: ${AUTHOR_EMAIL}${NC}"
156+
echo ""
157+
echo "Available GPG keys:"
158+
gpg --list-secret-keys --keyid-format=long | grep -A 1 ^sec
159+
echo ""
160+
echo "Either:"
161+
echo " 1. Generate a key with your email: gpg --full-generate-key"
162+
echo " 2. Or manually set signing key: git config user.signingkey <KEY_ID>"
163+
echo ""
164+
exit 1
165+
fi
166+
167+
git config user.signingkey "${GPG_KEY_ID}"
168+
git config commit.gpgsign true
169+
170+
echo -e "${GREEN}✅ GPG signing enabled${NC}"
171+
echo " Signing key: ${GPG_KEY_ID}"
172+
echo " All commits will be cryptographically signed"
173+
echo ""
174+
175+
# Test GPG signing
176+
echo "🧪 Testing GPG signature..."
177+
if echo "test" | gpg --clearsign --default-key "${GPG_KEY_ID}" &>/dev/null; then
178+
echo -e "${GREEN}✅ GPG signing test successful${NC}"
179+
else
180+
echo -e "${YELLOW}⚠️ GPG signing test failed${NC}"
181+
echo ""
182+
echo "Your GPG key may require a passphrase or additional configuration."
183+
echo ""
184+
echo "If you're on macOS/Linux, add this to your shell profile:"
185+
echo " export GPG_TTY=\$(tty)"
186+
echo ""
187+
echo "If using VS Code or IDE:"
188+
echo " git config --global gpg.program gpg"
189+
echo ""
190+
fi
191+
echo ""
192+
193+
###############################################################################
194+
# Step 4: Configure GPG Agent (for passphrase caching)
195+
###############################################################################
196+
197+
echo "📝 Step 4: Configuring GPG agent..."
198+
echo ""
199+
200+
# Ensure GPG agent is running
201+
if pgrep -x "gpg-agent" &>/dev/null; then
202+
echo -e "${GREEN}✅ GPG agent is running${NC}"
203+
else
204+
echo -e "${YELLOW}⚠️ Starting GPG agent...${NC}"
205+
gpg-agent --daemon &>/dev/null || true
206+
fi
207+
208+
# Check shell profile for GPG_TTY
209+
SHELL_PROFILE=""
210+
if [[ -f "${HOME}/.zshrc" ]]; then
211+
SHELL_PROFILE="${HOME}/.zshrc"
212+
elif [[ -f "${HOME}/.bashrc" ]]; then
213+
SHELL_PROFILE="${HOME}/.bashrc"
214+
fi
215+
216+
if [[ -n "${SHELL_PROFILE}" ]]; then
217+
if ! grep -q "export GPG_TTY" "${SHELL_PROFILE}" 2>/dev/null; then
218+
echo ""
219+
echo -e "${BLUE}💡 Tip: Add this to your ${SHELL_PROFILE##*/} for better GPG integration:${NC}"
220+
echo " export GPG_TTY=\$(tty)"
221+
echo ""
222+
fi
223+
fi
224+
225+
echo ""
226+
227+
###############################################################################
228+
# Summary
229+
###############################################################################
230+
231+
echo "═══════════════════════════════════════════════════════════════"
232+
echo -e "${GREEN}✅ Git configuration complete!${NC}"
233+
echo "═══════════════════════════════════════════════════════════════"
234+
echo ""
235+
echo "Configuration applied for:"
236+
echo " 👤 Author: ${AUTHOR_NAME} <${AUTHOR_EMAIL}>"
237+
echo " ✅ DCO sign-off: Automatic (format.signoff = true)"
238+
echo " ✅ GPG signing: Automatic (commit.gpgsign = true)"
239+
echo " 🔑 GPG key: ${GPG_KEY_ID}"
240+
echo ""
241+
echo "Your commits will now automatically include:"
242+
echo " 1. 🔏 GPG signature (cryptographic verification)"
243+
echo " 2. ✍️ DCO sign-off (Signed-off-by: ${AUTHOR_NAME} <${AUTHOR_EMAIL}>)"
244+
echo ""
245+
echo "Test it:"
246+
echo " git commit -m \"test: verify automatic signatures\""
247+
echo " git log -1 --show-signature"
248+
echo " git verify-commit HEAD"
249+
echo ""
250+
echo -e "${YELLOW}⚠️ Security Reminder:${NC}"
251+
echo " - Never commit with another developer's identity"
252+
echo " - Keep your GPG passphrase secure"
253+
echo " - Add your GPG public key to GitHub: https://github.com/settings/keys"
254+
echo ""
255+
echo "═══════════════════════════════════════════════════════════════"

.github/workflows/changeset-check.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
pull_request:
55
branches:
66
- develop
7+
- development
78
types:
89
- opened
910
- synchronize
@@ -73,7 +74,7 @@ jobs:
7374
git diff develop...HEAD --name-only --diff-filter=A | head -10
7475
echo ""
7576
echo "NEW changeset files in this PR: ${NEW_CHANGESET_COUNT}"
76-
if [ -n "${NEW_CHANGESETS}" ]; then
77+
if [[ -n "${NEW_CHANGESETS}" ]]; then
7778
echo "Found NEW changesets:"
7879
echo "${NEW_CHANGESETS}"
7980
fi
@@ -108,7 +109,7 @@ jobs:
108109
- name: Success summary
109110
if: ${{ always() }}
110111
run: |
111-
if [ "${{ steps.bypass.outputs.bypass }}" = "true" ]; then
112+
if [[ "${{ steps.bypass.outputs.bypass }}" == "true" ]]; then
112113
echo "✅ Changeset check bypassed due to label"
113114
else
114115
echo "✅ Changeset validation completed successfully"

.husky/commit-msg

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,89 @@
1+
###############################################################################
2+
# Commit Message Hook - DCO Sign-off Verification
3+
#
4+
# This hook verifies that commit messages include DCO sign-off.
5+
# If missing and format.signoff is not configured, it auto-adds it.
6+
#
7+
# Part of Layer 2: Commit-time enforcement
8+
###############################################################################
9+
10+
COMMIT_MSG_FILE="$1"
11+
COMMIT_MSG=$(cat "$COMMIT_MSG_FILE")
12+
13+
# Colors for output
14+
RED='\033[0;31m'
15+
YELLOW='\033[1;33m'
16+
GREEN='\033[0;32m'
17+
BLUE='\033[0;34m'
18+
NC='\033[0m' # No Color
19+
20+
###############################################################################
21+
# Check for DCO Sign-off
22+
###############################################################################
23+
24+
# Check if commit message already has DCO sign-off
25+
if echo "$COMMIT_MSG" | grep -q "^Signed-off-by: "; then
26+
# DCO sign-off is present, proceed to commitlint
27+
npm run commitlint
28+
exit $?
29+
fi
30+
31+
###############################################################################
32+
# DCO Missing - Check if format.signoff is enabled
33+
###############################################################################
34+
35+
FORMAT_SIGNOFF=$(git config --get format.signoff || echo "false")
36+
37+
if [ "$FORMAT_SIGNOFF" = "true" ]; then
38+
# format.signoff is enabled but DCO still missing (shouldn't happen)
39+
# This means git commit was called without proper flags
40+
echo ""
41+
echo -e "${YELLOW}⚠️ Warning: DCO sign-off missing despite format.signoff=true${NC}"
42+
echo ""
43+
echo "This commit would fail pre-push hook verification."
44+
echo ""
45+
echo "Git should have added DCO automatically. This might indicate:"
46+
echo " - You used 'git commit --no-signoff' (overrides config)"
47+
echo " - An IDE/tool bypassed git config"
48+
echo ""
49+
echo "Fix: Cancel this commit and use:"
50+
echo " git commit --signoff"
51+
echo ""
52+
exit 1
53+
fi
54+
55+
###############################################################################
56+
# Auto-add DCO Sign-off (Fallback)
57+
###############################################################################
58+
59+
# Get author information
60+
AUTHOR_NAME=$(git config user.name)
61+
AUTHOR_EMAIL=$(git config user.email)
62+
63+
if [ -z "$AUTHOR_NAME" ] || [ -z "$AUTHOR_EMAIL" ]; then
64+
echo ""
65+
echo -e "${RED}❌ ERROR: Git identity not configured${NC}"
66+
echo ""
67+
echo "You must configure your Git identity:"
68+
echo " git config user.name \"Your Name\""
69+
echo " git config user.email \"your.email@example.com\""
70+
echo ""
71+
exit 1
72+
fi
73+
74+
# Add DCO sign-off line
75+
echo "" >> "$COMMIT_MSG_FILE"
76+
echo "Signed-off-by: $AUTHOR_NAME <$AUTHOR_EMAIL>" >> "$COMMIT_MSG_FILE"
77+
78+
echo ""
79+
echo -e "${GREEN}✅ DCO sign-off automatically added${NC}"
80+
echo " Signed-off-by: $AUTHOR_NAME <$AUTHOR_EMAIL>"
81+
echo ""
82+
echo -e "${BLUE}💡 Tip: Enable automatic DCO for all commits:${NC}"
83+
echo " git config format.signoff true"
84+
echo " Or run: bash .github/scripts/setup-git.sh"
85+
echo ""
86+
87+
# Run commitlint on the modified message
188
npm run commitlint
89+
exit $?

0 commit comments

Comments
 (0)