Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
name: Bug report
about: Create a report to help us improve
title: "[BUG] "
labels: bug
assignees: ""
---

## Describe the bug

A clear and concise description of what the bug is.

## To Reproduce

Steps to reproduce the behavior:

1. Add action with inputs '...'
2. Run workflow on '...'
3. See error

## Expected behavior

A clear and concise description of what you expected to happen.

## Workflow configuration

```yaml
# Paste your workflow file or relevant section here
```

## Runner information

- OS: [e.g., ubuntu-latest, macos-latest]
- Runner version: [if known]

## Error logs

```
Paste relevant error messages here
```

## Additional context

Add any other context about the problem here.

27 changes: 27 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: Feature request
about: Suggest an idea for this project
title: '[FEATURE] '
labels: enhancement
assignees: ''
---

## Is your feature request related to a problem?
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

## Describe the solution you'd like
A clear and concise description of what you want to happen.

## Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

## Additional context
Add any other context or screenshots about the feature request here.

## Example usage
If applicable, show how you would like to use this feature:
```yaml
# Example workflow usage
```


36 changes: 36 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## Description
<!-- Provide a brief description of the changes in this PR -->

## Type of change
<!-- Mark the relevant option with an "x" -->

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update
- [ ] Other (please describe):

## Related Issues
<!-- Link to related issues using #issue-number -->
Fixes #

## Testing
<!-- Describe the tests you ran to verify your changes -->

- [ ] Tested on ubuntu-latest
- [ ] Tested on macos-latest
- [ ] Verified Auth0 CLI installation
- [ ] Verified Auth0 CLI authentication
- [ ] Tested Auth0 CLI commands after setup

## Checklist
- [ ] My code follows the project's guidelines
- [ ] I have updated the documentation accordingly
- [ ] I have added/updated tests if applicable
- [ ] All tests pass locally
- [ ] I have updated the CHANGELOG.md

## Additional context
<!-- Add any other context about the PR here -->


45 changes: 45 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Release

on:
push:
branches:
- main

permissions:
contents: write
pull-requests: write

jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.GITHUB_TOKEN }}
release-type: simple

# Update major version tag (e.g., v1) using GitHub API
# This respects repository signing settings automatically
- name: Update major version tag
if: steps.release.outputs.release_created
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
RELEASE_TAG=${{ steps.release.outputs.tag_name }}
MAJOR_VERSION=$(echo $RELEASE_TAG | cut -d. -f1)
SHA=${{ steps.release.outputs.sha }}

echo "Updating $MAJOR_VERSION to point to $RELEASE_TAG ($SHA)"

# Update or create major version tag
gh api /repos/${{ github.repository }}/git/refs/tags/$MAJOR_VERSION \
-X PATCH \
-f sha="$SHA" \
-F force=true \
|| gh api /repos/${{ github.repository }}/git/refs \
-X POST \
-f ref="refs/tags/$MAJOR_VERSION" \
-f sha="$SHA"

echo "✅ Updated $MAJOR_VERSION tag"
37 changes: 37 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Test Action
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch: # Allows manual triggering

jobs:
test:
name: Test on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
fail-fast: false

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Test Setup Auth0 CLI
uses: ./
with:
auth0-domain: ${{ secrets.AUTH0_DOMAIN }}
auth0-client-id: ${{ secrets.AUTH0_CLIENT_ID }}
auth0-client-secret: ${{ secrets.AUTH0_CLIENT_SECRET }}

- name: Verify Auth0 CLI is installed
run: |
auth0 --version
which auth0

- name: Test Auth0 CLI command
run: |
echo "Testing Auth0 CLI with a simple command..."
auth0 apps list || echo "Command executed (may have permissions restrictions)"
16 changes: 16 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# macOS
.DS_Store

# IDE
.vscode/
.idea/
*.swp
*.swo
*~

# Logs
*.log

# Testing
node_modules/

3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "0.0.0"
}
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

This file is automatically updated by [release-please](https://github.com/googleapis/release-please).
98 changes: 98 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
# Contributing to Setup Auth0 CLI Action

Thank you for your interest in contributing! This document provides guidelines for contributing to this project.

## How to Contribute

### Reporting Issues

If you find a bug or have a suggestion:

1. Check if the issue already exists in the [Issues](https://github.com/your-username/setup-auth0-cli/issues) section
2. If not, create a new issue with:
- Clear title and description
- Steps to reproduce (for bugs)
- Expected vs actual behavior
- Your runner OS (ubuntu-latest, macos-latest, etc.)
- Relevant logs or error messages

### Submitting Changes

1. Fork the repository
2. Create a new branch for your feature/fix:
```bash
git checkout -b feature/your-feature-name
```
3. Make your changes
4. Test your changes thoroughly
5. Commit with a clear message:
```bash
git commit -m "Add: brief description of changes"
```
6. Push to your fork:
```bash
git push origin feature/your-feature-name
```
7. Open a Pull Request with:
- Description of changes
- Reference to related issues
- Testing performed

### Testing Your Changes

Before submitting a PR, test your changes:

1. Create a test repository with your modified action
2. Run workflows on different runners (ubuntu, macos)
3. Verify the Auth0 CLI installs correctly
4. Test authentication with real Auth0 credentials
5. Run at least one Auth0 CLI command after setup

Example test workflow:

```yaml
name: Test Action
on: [push]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v4
- uses: ./
with:
auth0-domain: ${{ secrets.AUTH0_DOMAIN }}
auth0-client-id: ${{ secrets.AUTH0_CLIENT_ID }}
auth0-client-secret: ${{ secrets.AUTH0_CLIENT_SECRET }}
- run: auth0 --version
- run: auth0 apps list
```

## Development Guidelines

### Code Style

- Use clear, descriptive variable names
- Add comments for complex logic
- Follow YAML best practices for action.yml

### Documentation

- Update README.md for new features
- Add examples for new functionality
- Keep documentation clear and beginner-friendly

### Versioning

This project follows [Semantic Versioning](https://semver.org/):

- MAJOR: Breaking changes
- MINOR: New features (backward compatible)
- PATCH: Bug fixes (backward compatible)

## Questions?

Feel free to open an issue for any questions about contributing!

Loading