Skip to content

Commit 1cc706d

Browse files
committed
Add initial release of Exult Usecode Syntax extension with packaging and CI/CD setup
- Implemented GitHub Actions workflows for packaging and publishing - Created comprehensive README, CHANGELOG, and LICENSE files - Added .gitignore and .vscodeignore for build artifacts - Included sample files and images for documentation - Updated package.json with necessary metadata and keywords
1 parent e4b825d commit 1cc706d

File tree

10 files changed

+446
-13
lines changed

10 files changed

+446
-13
lines changed

.github/workflows/publish.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: Package and Publish Extension
2+
3+
on:
4+
# Trigger on version tags (e.g., v0.1.0, v1.2.3)
5+
push:
6+
tags:
7+
- "v*.*.*"
8+
9+
# Allow manual trigger from GitHub UI
10+
workflow_dispatch:
11+
12+
jobs:
13+
package:
14+
name: Package Extension
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
20+
21+
- name: Setup Node.js
22+
uses: actions/setup-node@v4
23+
with:
24+
node-version: "18"
25+
26+
- name: Install vsce
27+
run: npm install -g vsce
28+
29+
- name: Package extension
30+
run: vsce package
31+
32+
- name: Upload VSIX artifact
33+
uses: actions/upload-artifact@v4
34+
with:
35+
name: vscode-extension
36+
path: "*.vsix"
37+
38+
publish:
39+
name: Publish to Marketplace
40+
runs-on: ubuntu-latest
41+
needs: package
42+
# Only publish on tag pushes (not manual triggers)
43+
if: startsWith(github.ref, 'refs/tags/')
44+
45+
steps:
46+
- name: Checkout repository
47+
uses: actions/checkout@v4
48+
49+
- name: Setup Node.js
50+
uses: actions/setup-node@v4
51+
with:
52+
node-version: "18"
53+
54+
- name: Install vsce
55+
run: npm install -g vsce
56+
57+
- name: Publish to VS Code Marketplace
58+
env:
59+
VSCE_TOKEN: ${{ secrets.VSCE_TOKEN }}
60+
run: vsce publish --pat "$VSCE_TOKEN"
61+
62+
- name: Create GitHub Release
63+
uses: softprops/action-gh-release@v1
64+
with:
65+
files: "*.vsix"
66+
generate_release_notes: true
67+
env:
68+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test-package.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Package Extension (Test)
2+
3+
on:
4+
# Trigger on pushes to main branch
5+
push:
6+
branches: [main, master]
7+
8+
# Trigger on pull requests
9+
pull_request:
10+
branches: [main, master]
11+
12+
jobs:
13+
test-package:
14+
name: Test Package
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
20+
21+
- name: Setup Node.js
22+
uses: actions/setup-node@v4
23+
with:
24+
node-version: "18"
25+
26+
- name: Install vsce
27+
run: npm install -g vsce
28+
29+
- name: Package extension (dry run)
30+
run: vsce package --out test-extension.vsix
31+
32+
- name: List package contents
33+
run: vsce ls
34+
35+
- name: Upload test VSIX
36+
uses: actions/upload-artifact@v4
37+
with:
38+
name: test-extension
39+
path: "test-extension.vsix"

.gitignore

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# VS Code Extension build artifacts
2+
*.vsix
3+
4+
# Node.js dependencies (if added later)
5+
node_modules/
6+
npm-debug.log*
7+
yarn-debug.log*
8+
yarn-error.log*
9+
10+
# OS-specific files
11+
.DS_Store
12+
.DS_Store?
13+
._*
14+
.Spotlight-V100
15+
.Trashes
16+
ehthumbs.db
17+
Thumbs.db
18+
19+
# Editor/IDE files
20+
.vscode/settings.json
21+
.vscode/launch.json
22+
.vscode/extensions.json
23+
*.swp
24+
*.swo
25+
*~
26+
27+
# Temporary files
28+
*.tmp
29+
*.temp
30+
*.log
31+
32+
# Build and packaging files
33+
out/
34+
dist/
35+
build/
36+
37+
# Test coverage
38+
coverage/
39+
.nyc_output/
40+
41+
# Environment files
42+
.env
43+
.env.local
44+
.env.development.local
45+
.env.test.local
46+
.env.production.local

.vscodeignore

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Files and directories to exclude from the packaged extension
2+
.vscode/
3+
.git/
4+
.gitignore
5+
.github/
6+
node_modules/
7+
*.vsix
8+
*.log
9+
.DS_Store
10+
Thumbs.db
11+
12+
# Development files
13+
vscode-usecode-syntax.code-workspace
14+
15+
# Test files (uncomment if you don't want samples in the package)
16+
# samples/

CHANGELOG.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
## [0.1.0] - 2025-09-28
6+
7+
### Added
8+
9+
- Initial release: TextMate grammars for UseCode (.uc/.ucc/.uh/.ucxt) and UseCode assembly (.uca)
10+
- Language configuration with brackets, auto-closing pairs, and surrounding pairs
11+
- Sample file at `samples/test.uc` for testing and verification
12+
- Comprehensive syntax highlighting for:
13+
- Keywords, types, operators, and control flow
14+
- Strings with escape sequences and rune escapes
15+
- Line and block comments
16+
- Preprocessor directives (#include, #game, #line, etc.)
17+
- Intrinsic function highlighting (UI_* functions)
18+
- Script commands and assembly mnemonics
19+
- Labels, numbers (hex and decimal), and identifiers
20+
21+
### Documentation & Packaging
22+
23+
- Added GPL-2.0-or-later LICENSE.md with proper markdown formatting
24+
- Created marketplace-ready README.md with features, installation, and usage instructions
25+
- Added CHANGELOG.md for tracking releases
26+
- Added comprehensive .gitignore for build artifacts and temporary files
27+
- Added .vscodeignore to exclude development files from packaged extension
28+
29+
### Package Metadata
30+
31+
- Updated package.json with marketplace-required fields:
32+
- License field set to "GPL-2.0-or-later"
33+
- Keywords for discoverability: "usecode", "exult", "ucc", "syntax", "language"
34+
- Icon placeholder reference
35+
- Repository, bugs, and homepage placeholder URLs (replace with actual repo)
36+
37+
### CI/CD
38+
39+
- Added GitHub Actions workflows:
40+
- `publish.yml` - Automated packaging and publishing on version tags
41+
- `test-package.yml` - Continuous integration testing of packaging on pushes/PRs
42+
- Workflows support automatic publishing to VS Code Marketplace using VSCE_TOKEN secret

0 commit comments

Comments
 (0)