xiaohongshu
xiaohongshu
just-automation-practices
Best practices for using just command runner and task automation in development workflows.
Full skill instructions
Guide for using the just command runner for task automation, covering recipe design, variable handling, and cross-platform development.
This skill activates when:
# Run tests
test:
uv run pytest
# Run with arguments
test-file file:
uv run pytest {{file}}
# Default recipe (runs when just called without arguments)
default: lint test
# Dependencies run first
build: lint test
uv run python -m build
# Clean before build
clean-build: clean build
# Simple variables
python := "uv run python"
pytest := "uv run pytest"
# Using variables
test:
{{pytest}} tests/
# Environment variables
export PYTHONPATH := "src"
test:
{{pytest}} tests/
# Current directory
project_dir := justfile_directory()
# Parent directory
parent := parent_directory(justfile_directory())
# Environment with default
python := env_var_or_default("PYTHON", "python3")
# Required argument
test file:
uv run pytest {{file}}
# Optional with default
test file="tests/":
uv run pytest {{file}}
# Variadic (all remaining args)
test *args:
uv run pytest {{args}}
# Named with defaults
build target="release" output="dist":
echo "Building {{target}} to {{output}}"
# Conditional execution
test:
#!/usr/bin/env bash
if [[ -f "tests/integration" ]]; then
uv run pytest tests/integration
fi
# Using just's if
python := if os() == "windows" { "python" } else { "python3" }
# With shebang
setup:
#!/usr/bin/env bash
set -euo pipefail
echo "Setting up environment..."
uv sync
echo "Done!"
# Default shell recipes
install:
uv sync
echo "Dependencies installed"
# Install dependencies
install:
uv sync
# Format code
format:
uv run ruff format .
# Lint code
lint:
uv run ruff check .
uv run basedpyright
# Run tests
test *args:
uv run pytest {{args}}
# Full check before commit
check: format lint test
# Clean artifacts
clean:
rm -rf dist/ .pytest_cache/ .coverage htmlcov/
# Build with options
build target="release":
#!/usr/bin/env bash
case "{{target}}" in
release)
uv run python -m build
;;
dev)
uv pip install -e .
;;
*)
echo "Unknown target: {{target}}"
exit 1
;;
esac
# Set environment for recipes
set dotenv-load := true
# Use .env file
test:
uv run pytest
# Override environment
test-ci:
CI=true uv run pytest
# Different commands per OS
open_browser := if os() == "macos" {
"open"
} else if os() == "windows" {
"start"
} else {
"xdg-open"
}
docs:
{{open_browser}} docs/_build/html/index.html
# Cross-platform paths
project_dir := justfile_directory()
src_dir := project_dir / "src"
tests_dir := project_dir / "tests"
# Show available recipes
just --list
# Show recipe with description
just --show test
# Recipe descriptions appear in --list
# Run all tests with coverage
test:
uv run pytest --cov
# Format code using ruff
format:
uv run ruff format .
# Main recipe
test-all:
uv run pytest
# Aliases for convenience
alias t := test-all
alias tests := test-all
Additional resources:
xiaohongshu
technical spec
product ux expert
database patterns
Conduct multi-agent task orchestration and workflow coordination.
Initialize project with Conductor artifacts (product definition,
Expert in web animations, transitions, and motion design using Framer Motion and CSS
Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...
PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.
Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...
Display project status, active tracks, and next actions
Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.
Generate, edit, and beat-sync AI video with leading models in one workspace.
The world's fastest calendar for remote work
Transform Your Design with AI Designer by ImgCreator.ai
Revolutionizing Video Production with AI-Powered Creativity
Extend an image past the frame and let AI fill the new aspect ratio.
Discover your celebrity doppelgänger with StarByFace!
ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.
Opus.ai: Revolutionize Your Web Experience