Compare commits
20
Commits
ee97ae20f8
..
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a3e11a6ad1 | ||
|
|
6313817cd4 | ||
|
|
f9fba50093 | ||
|
|
c50b53cea0 | ||
|
|
7ee6b4969e | ||
|
|
1ef65523d3 | ||
|
|
738b727242 | ||
|
|
068ac93e40 | ||
|
|
53d642bbb7 | ||
|
|
f0ecd16cb0 | ||
|
|
2a4dd82643 | ||
|
|
d33cfd6ccc | ||
|
|
d2b1d1e8cc | ||
|
|
ccd9cd9c94 | ||
|
|
f310eeba9b | ||
|
|
f956aee811 | ||
|
|
2146dd3f46 | ||
|
|
393cda8785 | ||
|
|
4fbf5c6b53 | ||
|
|
cdd2202839 |
@@ -0,0 +1,14 @@
|
||||
# TODO: delete this file if unused
|
||||
# This is on the only .env file commited to git.
|
||||
# It's purpose is to provide an environment from which it can operate the app and do full development.
|
||||
|
||||
DATABASE_URL=postgres://app_client:app_password@localhost:5432/inventory_2?sslmode=disable
|
||||
TEST_DATABASE_URL=postgres://app_client:app_password@localhost:5432/inventory_2_test?sslmode=disable
|
||||
|
||||
# AUTH0_DOMAIN / AUTH0_CLIENT_ID / AUTH0_CLIENT_SECRET / AUTH0_CALLBACK_URL
|
||||
# are intentionally omitted: with DEV_AUTH_ENABLED=true below, real Auth0
|
||||
# login never runs, so config.Load() doesn't require them.
|
||||
|
||||
DEV_AUTH_ENABLED=true
|
||||
|
||||
PORT=8090
|
||||
@@ -0,0 +1,121 @@
|
||||
name: Claude Assistant for Gitea
|
||||
|
||||
on:
|
||||
# Trigger on issue comments (works on both issues and pull requests in Gitea)
|
||||
issue_comment:
|
||||
types: [created]
|
||||
# Trigger on issues being opened or assigned
|
||||
issues:
|
||||
types: [opened, assigned]
|
||||
# Note: pull_request_review_comment has limited support in Gitea
|
||||
# Use issue_comment instead which covers PR comments
|
||||
|
||||
jobs:
|
||||
claude-assistant:
|
||||
# Basic trigger detection - check for @claude in comments or issue body
|
||||
if: |
|
||||
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
|
||||
(github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || github.event.action == 'assigned'))
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: write
|
||||
issues: write
|
||||
# Note: Gitea Actions may not require id-token: write for basic functionality
|
||||
|
||||
services:
|
||||
postgres:
|
||||
image: postgres
|
||||
env:
|
||||
POSTGRES_PASSWORD: postgres
|
||||
options: >-
|
||||
--health-cmd pg_isready
|
||||
--health-interval 10s
|
||||
--health-timeout 5s
|
||||
--health-retries 5
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Setup golang environment
|
||||
uses: actions/setup-go@v7
|
||||
with:
|
||||
go-version: 'stable'
|
||||
check-latest: true
|
||||
token: ${{ gitea.token }}
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
- name: Setup node environment
|
||||
uses: actions/setup-node@v7
|
||||
with:
|
||||
# Version Spec of the version to use in SemVer notation.
|
||||
# It also admits such aliases as lts/*, latest, nightly and canary builds
|
||||
# Examples: 12.x, 10.15.1, >=10.15.0, lts/Hydrogen, 16-nightly, latest, node
|
||||
node-version: 24
|
||||
|
||||
# Set this option if you want the action to check for the latest available version
|
||||
# that satisfies the version spec.
|
||||
# It will only get affect for lts Nodejs versions (12.x, >=10.15.0, lts/Hydrogen).
|
||||
# Default: false
|
||||
#check-latest: false
|
||||
|
||||
package-manager-cache: false # Maybe add caching later
|
||||
|
||||
# Used to pull node distributions from https://github.com/actions/node-versions.
|
||||
# Since there's a default, this is typically not supplied by the user.
|
||||
# When running this action on github.com, the default value is sufficient.
|
||||
# When running on GHES, you can pass a personal access token for github.com if you are experiencing rate limiting.
|
||||
#
|
||||
# We recommend using a service account with the least permissions necessary. Also
|
||||
# when generating a new PAT, select the least scopes necessary.
|
||||
#
|
||||
# [Learn more about creating and using encrypted secrets](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets)
|
||||
#
|
||||
# Default: ${{ github.server_url == 'https://github.com' && github.token || '' }}
|
||||
token: ${{ secrets.GITEA_TOKEN }}
|
||||
|
||||
- name: Run Claude Assistant
|
||||
uses: markwylde/claude-code-gitea-action@gitea
|
||||
with:
|
||||
allowed_tools: |
|
||||
penpot-self-hosted__execute_code
|
||||
penpot-self-hosted__high_level_overview
|
||||
penpot-self-hosted__penpot_api_info
|
||||
penpot-self-hosted__export_shape
|
||||
penpot_self_hosted__execute_code
|
||||
penpot_self_hosted__high_level_overview
|
||||
penpot_self_hosted__penpot_api_info
|
||||
penpot_self_hosted__export_shape
|
||||
Bash(go:*)
|
||||
Bash(gofmt:*)
|
||||
Bash(./tailwind.sh)
|
||||
Bash(node -v)
|
||||
Bash(npm install)
|
||||
Bash(psql:*)
|
||||
gitea_api_url: "https://gitea.inventory-plus-plus.com/api/v1"
|
||||
gitea_token: ${{ secrets.GITEA_TOKEN }} # Use standard workflow token
|
||||
# anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
|
||||
# Prefer claude_code_oauth_token over anthropic_api_key (cheaper!)
|
||||
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
|
||||
timeout_minutes: "60"
|
||||
trigger_phrase: "@claude"
|
||||
assignee_trigger: "@claude"
|
||||
# Needed due to bug: https://github.com/anthropics/claude-code-action/issues/1416
|
||||
model: "claude-sonnet-5"
|
||||
# Optional: Customize for Gitea environment
|
||||
custom_instructions: |
|
||||
You are working in a Gitea environment. Be aware that:
|
||||
- Some GitHub Actions features may behave differently
|
||||
- Focus on core functionality and avoid advanced GitHub-specific features
|
||||
- Use standard git operations when possible
|
||||
env:
|
||||
GITEA_SERVER_URL: "https://gitea.inventory-plus-plus.com"
|
||||
NODE_VERSION: 24.x
|
||||
POSTGRES_HOST: postgres
|
||||
POSTGRES_PORT: 5432
|
||||
DATABASE_URL: postgres://app_client:app_password@localhost:5432/inventory_2?sslmode=disable
|
||||
TEST_DATABASE_URL: postgres://app_client:app_password@localhost:5432/inventory_2_test?sslmode=disable
|
||||
+1
-1
@@ -5,4 +5,4 @@ node_modules
|
||||
|
||||
.env
|
||||
.env.*
|
||||
.env.example
|
||||
!.env.gitea-claude-bot-dev
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"mcpServers": {
|
||||
"penpot-self-hosted": {
|
||||
"description": "Set here, even though set globally, so it is also available for the gitea-claude action bot",
|
||||
"type": "http",
|
||||
"url": "https://penpot.inventory-plus-plus.com/mcp/stream?userToken=${PENPOT_MCP_USER_TOKEN}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -249,6 +249,27 @@ against the live API doesn't exist yet.
|
||||
you test multiple identities/accounts side by side. Never enable this
|
||||
outside local development.
|
||||
|
||||
## Gitea
|
||||
|
||||
- This project is hosted on a self-hosted **Gitea** instance at
|
||||
`gitea.inventory-plus-plus.com` (repo:
|
||||
`angel/inventory-plus-plus`), not GitHub - the `origin` remote points at
|
||||
it over SSH. Issues, pull requests, wiki, and CI (Gitea Actions - see the
|
||||
Tests badge at the top of `README.md`) all live there rather than on
|
||||
GitHub, even though the tooling/workflow (Actions YAML, PR-based review)
|
||||
looks GitHub-shaped.
|
||||
- A Gitea MCP server is available in agent sessions (tools prefixed
|
||||
`mcp__angel__...` - e.g. `issue_read`/`issue_write`,
|
||||
`pull_request_read`/`pull_request_write`,
|
||||
`list_pull_requests`/`list_issues`, `list_branches`, `wiki_read`/
|
||||
`wiki_write`) for reading/managing issues, PRs, branches, releases, and
|
||||
the wiki without shelling out to `git`/`gh`. There is no GitHub CLI
|
||||
(`gh`) equivalent here - use these MCP tools or `git` directly instead.
|
||||
- The Gitea MCP server has **no Projects API** - it cannot read or modify
|
||||
Gitea Project boards. Don't attempt to automate Project-board changes
|
||||
(e.g. moving an issue between columns) through it; that has to be done
|
||||
manually in the Gitea UI.
|
||||
|
||||
## Commit conventions
|
||||
|
||||
- Commit messages: imperative mood subject line, no period, body explains
|
||||
|
||||
@@ -17,6 +17,8 @@ Documentation is split up rather than kept in one big doc - start here:
|
||||
- **[`domains/platforms/etsy/COMPLIANCE.md`](./domains/platforms/etsy/COMPLIANCE.md)** - Etsy API usage obligations to keep satisfied when touching the Etsy integration.
|
||||
- **[`diagrams/`](./diagrams)** - architecture and schema diagrams, linked from the Diagrams section below.
|
||||
|
||||
This project is hosted on a self-hosted [Gitea](https://gitea.inventory-plus-plus.com/angel/inventory-plus-plus) instance (not GitHub) - issues, pull requests, CI (the Tests badge above), and the wiki all live there. See `AGENTS.md`'s Gitea section for details, including the Gitea MCP server tools available to AI agents.
|
||||
|
||||
|
||||
## Deploying
|
||||
|
||||
|
||||
Reference in New Issue
Block a user