Skip to content
Open
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
66 changes: 66 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Tests

on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]

jobs:
test:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']

steps:
- uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest

- name: Run tests
run: |
pytest test_trashclaw.py -v --tb=short

- name: Verify zero dependencies
run: |
python -c "
import ast
import sys

with open('trashclaw.py', 'r') as f:
tree = ast.parse(f.read())

imports = []
for node in ast.walk(tree):
if isinstance(node, ast.Import):
for alias in node.names:
imports.append(alias.name)
elif isinstance(node, ast.ImportFrom):
imports.append(node.module)

# Allowed stdlib modules
ALLOWED = {
'os', 'sys', 'json', 'subprocess', 'urllib.request', 'urllib.error',
're', 'glob', 'difflib', 'traceback', 'time', 'signal', 'datetime',
'typing', 'base64', 'random', 'platform', 'hashlib', 'readline',
'pyreadline3' # Windows optional
}

external = [i for i in imports if i and not any(i.startswith(a) for a in ALLOWED)]
if external:
print(f'ERROR: External dependencies found: {external}')
sys.exit(1)
else:
print('✓ Zero external dependencies verified')
"
22 changes: 22 additions & 0 deletions TIPS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# TrashClaw Quick Tips

## Windows Terminal

- Use PowerShell for Windows commands
- Ctrl+Shift+C to copy from terminal
- Ctrl+Shift+V to paste to terminal

## Common Commands

```powershell
# Start trashclaw
openclaw start

# Check status
openclaw gateway status
```n
## Pro Tips

1. Add trashclaw to PATH for easy access
2. Use aliases for frequently used commands
3. Keep your workspace organized
Loading