Skip to content

Commit 8fcf430

Browse files
committed
Initial commit: DevXP CLI - Gamified developer productivity tool 🎮
0 parents  commit 8fcf430

71 files changed

Lines changed: 27847 additions & 0 deletions

Some content is hidden

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

.dockerignore

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
node_modules
2+
npm-debug.log
3+
Dockerfile
4+
.dockerignore
5+
.git
6+
.gitignore
7+
README.md
8+
.env
9+
coverage
10+
.nyc_output
11+
.github
12+
.vscode
13+
.idea
14+
dist
15+
*.log
16+
*.db
17+
*.sqlite
18+
*.sqlite3
19+
.DS_Store
20+
*.swp
21+
*~
22+
tmp
23+
temp
24+
.cache

.github/workflows/ci.yml

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
name: CI/CD
2+
3+
on:
4+
push:
5+
branches: [ main, master ]
6+
pull_request:
7+
branches: [ main, master ]
8+
release:
9+
types: [created]
10+
11+
jobs:
12+
test:
13+
runs-on: ${{ matrix.os }}
14+
15+
strategy:
16+
matrix:
17+
os: [ubuntu-latest, windows-latest, macos-latest]
18+
node-version: [18.x, 20.x, 22.x]
19+
20+
steps:
21+
- name: Checkout code
22+
uses: actions/checkout@v4
23+
24+
- name: Setup Node.js
25+
uses: actions/setup-node@v4
26+
with:
27+
node-version: ${{ matrix.node-version }}
28+
cache: 'npm'
29+
30+
- name: Install dependencies
31+
run: npm ci
32+
33+
- name: Run linter
34+
run: npm run lint
35+
36+
- name: Check formatting
37+
run: npm run format:check
38+
39+
- name: Run unit tests
40+
run: npm run test:unit
41+
42+
- name: Run integration tests
43+
run: npm run test:integration
44+
45+
- name: Generate coverage report
46+
if: matrix.os == 'ubuntu-latest' && matrix.node-version == '20.x'
47+
run: npm run test:coverage
48+
49+
- name: Upload coverage to Codecov
50+
if: matrix.os == 'ubuntu-latest' && matrix.node-version == '20.x'
51+
uses: codecov/codecov-action@v4
52+
with:
53+
file: ./coverage/coverage-final.json
54+
flags: unittests
55+
name: codecov-umbrella
56+
57+
- name: Build project
58+
run: npm run build
59+
60+
- name: Test CLI installation
61+
run: |
62+
npm link
63+
devxp --version
64+
devxp --help
65+
66+
publish-npm:
67+
needs: test
68+
runs-on: ubuntu-latest
69+
if: github.event_name == 'release'
70+
71+
steps:
72+
- name: Checkout code
73+
uses: actions/checkout@v4
74+
75+
- name: Setup Node.js
76+
uses: actions/setup-node@v4
77+
with:
78+
node-version: '20.x'
79+
registry-url: 'https://registry.npmjs.org'
80+
81+
- name: Install dependencies
82+
run: npm ci
83+
84+
- name: Build project
85+
run: npm run build
86+
87+
- name: Publish to npm
88+
run: npm publish
89+
env:
90+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
91+
92+
docker:
93+
needs: test
94+
runs-on: ubuntu-latest
95+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
96+
97+
steps:
98+
- name: Checkout code
99+
uses: actions/checkout@v4
100+
101+
- name: Set up Docker Buildx
102+
uses: docker/setup-buildx-action@v3
103+
104+
- name: Login to DockerHub
105+
uses: docker/login-action@v3
106+
with:
107+
username: ${{ secrets.DOCKER_USERNAME }}
108+
password: ${{ secrets.DOCKER_PASSWORD }}
109+
110+
- name: Build and push Docker image
111+
uses: docker/build-push-action@v5
112+
with:
113+
context: .
114+
push: true
115+
tags: |
116+
${{ secrets.DOCKER_USERNAME }}/devxp-cli:latest
117+
${{ secrets.DOCKER_USERNAME }}/devxp-cli:${{ github.sha }}

.gitignore

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# Dependencies
2+
node_modules/
3+
npm-debug.log*
4+
yarn-debug.log*
5+
yarn-error.log*
6+
pnpm-debug.log*
7+
8+
# Build output
9+
dist/
10+
build/
11+
out/
12+
*.tsbuildinfo
13+
14+
# IDE and editor files
15+
.vscode/
16+
.idea/
17+
*.swp
18+
*.swo
19+
*~
20+
.DS_Store
21+
Thumbs.db
22+
23+
# Environment files
24+
.env
25+
.env.local
26+
.env.*.local
27+
28+
# Test coverage
29+
coverage/
30+
*.lcov
31+
.nyc_output/
32+
33+
# Logs
34+
logs/
35+
*.log
36+
37+
# Temporary files
38+
tmp/
39+
temp/
40+
.tmp/
41+
42+
# OS files
43+
Desktop.ini
44+
45+
# Package manager files
46+
.pnp.*
47+
.yarn/*
48+
!.yarn/patches
49+
!.yarn/plugins
50+
!.yarn/releases
51+
!.yarn/sdks
52+
!.yarn/versions

.npmignore

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
# Source files (only publish compiled)
2+
src/
3+
*.ts
4+
!*.d.ts
5+
6+
# Test files
7+
tests/
8+
e2e/
9+
*.test.ts
10+
*.spec.ts
11+
jest.config.js
12+
jest.setup.js
13+
playwright.config.ts
14+
coverage/
15+
.nyc_output/
16+
17+
# Development files
18+
.github/
19+
.vscode/
20+
.idea/
21+
*.log
22+
*.swp
23+
.DS_Store
24+
node_modules/
25+
.env
26+
.env.local
27+
.env.*.local
28+
29+
# Documentation source files
30+
docs/
31+
*.md
32+
!README.md
33+
!LICENSE
34+
!CHANGELOG.md
35+
36+
# Configuration files
37+
.eslintrc*
38+
.prettierrc*
39+
.gitignore
40+
.npmignore
41+
tsconfig.json
42+
eslint.config.mjs
43+
44+
# Build artifacts
45+
*.map
46+
*.tsbuildinfo
47+
48+
# Shell scripts
49+
*.sh
50+
install.sh
51+
uninstall.sh
52+
setup_wizard.sh
53+
54+
# Database files
55+
*.db
56+
*.sqlite
57+
*.sqlite3
58+
59+
# Temporary files
60+
tmp/
61+
temp/
62+
.cache/
63+
64+
# IDE specific
65+
.idea/
66+
.vscode/
67+
*.sublime-*
68+
*.code-workspace
69+
70+
# OS specific
71+
Thumbs.db
72+
.DS_Store
73+
*.swp
74+
*~

.prettierignore

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
dist/
2+
node_modules/
3+
*.min.js
4+
coverage/
5+
.next/
6+
build/
7+
package-lock.json
8+
yarn.lock
9+
pnpm-lock.yaml

.prettierrc.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"semi": true,
3+
"trailingComma": "es5",
4+
"singleQuote": true,
5+
"printWidth": 100,
6+
"tabWidth": 2,
7+
"useTabs": false,
8+
"bracketSpacing": true,
9+
"arrowParens": "always",
10+
"endOfLine": "lf"
11+
}

CHANGELOG.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## [Unreleased]
9+
10+
### Added
11+
- Initial release of DevXP CLI
12+
- Core XP and leveling system
13+
- Achievement tracking and unlocking
14+
- Shell integration for Bash, Zsh, and Fish
15+
- Git hooks integration for automatic tracking
16+
- Beautiful terminal visualizations with gradients and animations
17+
- SQLite database for persistent data storage
18+
- Comprehensive statistics tracking
19+
- Leaderboard functionality
20+
- Configuration management system
21+
- Interactive setup wizard
22+
- Command autocompletion support
23+
24+
### Features
25+
- `status` command to display current level and XP
26+
- `achievements` command to view all achievements
27+
- `stats` command to show coding statistics
28+
- `leaderboard` command for rankings
29+
- `config` command for settings management
30+
- `install` command for setup wizard
31+
- `reset` command to reset progress
32+
- `shell-integration` command for shell setup
33+
34+
## [1.0.0] - 2024-01-01
35+
36+
### Added
37+
- Initial stable release
38+
- Full documentation and examples
39+
- Comprehensive test suite
40+
- CI/CD pipeline with GitHub Actions
41+
- npm package publication setup
42+
- MIT License
43+
44+
[Unreleased]: https://github.com/yourusername/devxp-cli/compare/v1.0.0...HEAD
45+
[1.0.0]: https://github.com/yourusername/devxp-cli/releases/tag/v1.0.0

0 commit comments

Comments
 (0)