diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index fe8995b..2e1f1a3 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -30,7 +30,7 @@ jobs: run: bun run action:build - name: Test action with preview mode - uses: ./ + uses: LukeHagar/usage-statistics@main with: preview-mode: 'true' json-output-path: 'test-stats.json' diff --git a/INSTALLATION.md b/INSTALLATION.md new file mode 100644 index 0000000..458945f --- /dev/null +++ b/INSTALLATION.md @@ -0,0 +1,97 @@ +# Quick Installation Guide + +## 🚀 Install the Usage Statistics Tracker + +### Basic Installation + +Add this to your GitHub Actions workflow: + +```yaml +- name: Usage Statistics Tracker + uses: LukeHagar/usage-statistics@v1 + with: + config: 'production' + json-output-path: 'stats.json' + update-readme: 'true' + github-token: ${{ secrets.GITHUB_TOKEN }} +``` + +### Complete Example Workflow + +```yaml +name: Update Usage Statistics + +on: + schedule: + - cron: '0 0 * * *' # Daily at midnight + workflow_dispatch: + +jobs: + update-stats: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Usage Statistics Tracker + uses: LukeHagar/usage-statistics@v1 + with: + config: 'production' + json-output-path: 'stats.json' + csv-output-path: 'stats.csv' + report-output-path: 'docs/usage-report.md' + update-readme: 'true' + github-token: ${{ secrets.GITHUB_TOKEN }} + + - name: Commit and push changes + run: | + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" + git add stats.json stats.csv docs/usage-report.md README.md + git commit -m "chore: update usage statistics [skip ci]" || echo "No changes to commit" + git push +``` + +### README Integration + +Add these markers to your README.md for automatic updates: + +```markdown + +## 📊 Usage Statistics + +Last updated: 2025-07-29T18:53:52.619Z + +### Summary +- **Total Downloads**: 414,533 +- **Unique Packages**: 8 +- **Platforms Tracked**: npm, pypi, homebrew, go + +### Top Packages +1. **node** (homebrew) - 226,882 downloads +2. **git** (homebrew) - 153,281 downloads +3. **axios** (npm) - 18,397 downloads +4. **lodash** (npm) - 15,914 downloads +5. **github.com/go-chi/chi** (go) - 33 downloads + +### Recent Activity +- **node** (homebrew) - 226,882 downloads on 7/29/2025 +- **git** (homebrew) - 153,281 downloads on 7/29/2025 +- **axios** (npm) - 722 downloads on 7/29/2025 +- **lodash** (npm) - 857 downloads on 7/29/2025 +- **axios** (npm) - 936 downloads on 7/28/2025 + +``` + +## 📚 Documentation + +- **Full Documentation**: [README.md](README.md) +- **Examples**: [examples/basic-usage.yml](examples/basic-usage.yml) +- **Repository**: [https://github.com/LukeHagar/usage-statistics](https://github.com/LukeHagar/usage-statistics) + +## 🤝 Support + +- **Issues**: [GitHub Issues](https://github.com/LukeHagar/usage-statistics/issues) +- **Discussions**: [GitHub Discussions](https://github.com/LukeHagar/usage-statistics/discussions) +- **Documentation**: [README.md](README.md) \ No newline at end of file diff --git a/PUBLISHING.md b/PUBLISHING.md index e9bd5c5..4381581 100644 --- a/PUBLISHING.md +++ b/PUBLISHING.md @@ -66,6 +66,7 @@ git push origin v1.0.0 #### Basic Information - **Action name**: `usage-statistics-tracker` - **Description**: `Track download statistics across multiple platforms (NPM, GitHub, PyPI, Homebrew, PowerShell, Postman, Go)` +- **Repository**: `LukeHagar/usage-statistics` - **Category**: Choose `Data` or `Utilities` - **Icon**: Upload a relevant icon (512x512px PNG recommended) - **Color**: Choose a brand color (e.g., `#0366d6` for blue) @@ -97,6 +98,7 @@ Add relevant keywords: #### Action Name - **Marketplace name**: `Usage Statistics Tracker` - **Description**: `Comprehensive GitHub Action for tracking download statistics across multiple platforms with configurable outputs and README integration` +- **Repository**: `LukeHagar/usage-statistics` #### Categories - **Primary category**: `Data` diff --git a/README.md b/README.md index 27cdf41..1d286a0 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ A comprehensive GitHub Action for tracking download statistics across multiple p ```yaml - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' json-output-path: 'stats.json' @@ -66,7 +66,7 @@ bun test #### Production Mode ```yaml - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' ``` @@ -74,7 +74,7 @@ bun test #### Development Mode ```yaml - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'development' ``` @@ -82,7 +82,7 @@ bun test #### Custom JSON Configuration ```yaml - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: '{"npmPackages": ["lodash", "axios"], "githubRepositories": ["microsoft/vscode"]}' ``` @@ -119,7 +119,7 @@ jobs: uses: actions/checkout@v4 - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' json-output-path: 'stats.json' @@ -139,7 +139,7 @@ jobs: ```yaml - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' json-output-path: 'data/stats.json' @@ -156,7 +156,7 @@ jobs: ```yaml - name: Test Usage Statistics - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: preview-mode: 'true' json-output-path: 'test-stats.json' @@ -170,7 +170,7 @@ jobs: ```yaml - name: Usage Statistics Tracker id: stats - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' json-output-path: 'stats.json' diff --git a/action.yml b/action.yml index 48c8ae6..646d30b 100644 --- a/action.yml +++ b/action.yml @@ -1,6 +1,6 @@ name: 'Usage Statistics Tracker' description: 'Track download statistics across multiple platforms (NPM, GitHub, PyPI, Homebrew, PowerShell, Postman, Go)' -author: 'Your Name' +author: 'LukeHagar' inputs: # Configuration diff --git a/examples/basic-usage.yml b/examples/basic-usage.yml index 4d848f1..bd877ee 100644 --- a/examples/basic-usage.yml +++ b/examples/basic-usage.yml @@ -14,7 +14,7 @@ jobs: uses: actions/checkout@v4 - name: Usage Statistics Tracker - uses: your-username/usage-statistics@v1 + uses: LukeHagar/usage-statistics@v1 with: config: 'production' json-output-path: 'stats.json' diff --git a/package.json b/package.json index bbd43a1..baff837 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,12 @@ { "name": "usage-statistics", "version": "1.0.0", - "description": "A Bun TypeScript script project", + "description": "A comprehensive GitHub Action for tracking download statistics across multiple platforms", + "repository": { + "type": "git", + "url": "https://github.com/LukeHagar/usage-statistics.git" + }, + "homepage": "https://github.com/LukeHagar/usage-statistics#readme", "main": "src/index.ts", "scripts": { "start": "bun run src/index.ts", @@ -23,5 +28,22 @@ }, "engines": { "bun": ">=1.0.0" - } + }, + "keywords": [ + "github-action", + "statistics", + "analytics", + "downloads", + "npm", + "github", + "pypi", + "homebrew", + "powershell", + "postman", + "go", + "tracking", + "usage" + ], + "author": "LukeHagar", + "license": "MIT" } \ No newline at end of file