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
File renamed without changes.
4 changes: 2 additions & 2 deletions .ansible/playbooks/setup-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@

- name: Import VS Code installation tasks
ansible.builtin.import_tasks: tasks/apt-release-code.yml
when: apt.releases.code | default(false) | bool
when: (apt.releases.code | default(false)) if apt.releases is defined else false
become: true
tags: [apt, code, vscode]

- name: Import Brave installation tasks
ansible.builtin.import_tasks: tasks/apt-release-brave.yml
when: apt.releases.brave | default(false) | bool
when: (apt.releases.brave | default(false)) if apt.releases is defined else false
become: true
tags: [apt, brave]

Expand Down
1 change: 1 addition & 0 deletions .ansible/variables-example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ dotfiles:
.bash_options: true
.bash_profile: true
.bashrc: true
.codespellrc: true
.ctags: true
.curlrc: true
.editorconfig: true
Expand Down
3 changes: 3 additions & 0 deletions .codespellrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[codespell]
skip = .git,*.pdf,*.svg
ignore-words-list = AKS
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
# Dependabot configuration file.
# @docs: <https://docs.github.com/en/code-security/reference/supply-chain-security/dependabot-options-reference>

version: 2
updates:
# Enable version updates for npm
- package-ecosystem: "npm"
# Look for `package.json` and `lock` files in the `root` directory
directory: "/"
# Check the npm registry for updates every day (weekdays)
schedule:
interval: "weekly"
22 changes: 22 additions & 0 deletions .github/workflows/check-pr-comment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: Check — PR Comment
# yamllint disable-line rule:truthy
on:
workflow_run:
workflows:
- Check
types:
- completed
permissions:
actions: read
checks: read
issues: write
pull-requests: write
jobs:
comment:
uses: kenorb/.github/.github/workflows/check-pr-comment.yml@main
with:
conclusion: ${{ github.event.workflow_run.conclusion }}
head_sha: ${{ github.event.workflow_run.head_sha }}
run_id: ${{ github.event.workflow_run.id }}
run_url: ${{ github.event.workflow_run.html_url }}
27 changes: 7 additions & 20 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,13 @@
---
name: Check

# yamllint disable-line rule:truthy
on:
pull_request:
push:

schedule:
- cron: 0 0 * * 1 # Run every Monday at 00:00 UTC
workflow_dispatch:
jobs:
Pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: ~/.cache/pre-commit
key: pre-commit|${{ hashFiles('.pre-commit-config.yaml') }}
- uses: actions/setup-python@v5
- name: Installs shfmt
run: >
curl -fsSL "$SHFMT_URL" | sudo tee /usr/local/bin/shfmt >/dev/null &&
sudo chmod +x /usr/local/bin/shfmt
env:
# yamllint disable rule:line-length
SHFMT_URL: https://github.com/mvdan/sh/releases/download/v3.1.1/shfmt_v3.1.1_linux_amd64
- uses: pre-commit/action@v3.0.1
check:
uses: kenorb/.github/.github/workflows/check.yml@main
with:
submodules: 'false' # Set to 'true' or 'recursive' if repository uses submodules
131 changes: 4 additions & 127 deletions .github/workflows/devcontainer-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ on:
paths:
- .devcontainer/**
- .github/workflows/devcontainer-ci.yml
types:
- opened
- synchronize
- reopened
- ready_for_review
push:
branches:
- dev
Expand All @@ -21,131 +16,13 @@ on:
- .github/workflows/devcontainer-ci.yml
schedule:
- cron: 0 0 * * 1 # Run every Monday at 00:00 UTC
workflow_call:
# IMPORTANT: When calling this reusable workflow from another repository,
# you MUST grant 'packages: write' permission in the calling workflow.
# Example:
# jobs:
# devcontainer:
# uses: Cogni-AI-OU/.github/.github/workflows/devcontainer-ci.yml@main
# permissions:
# contents: read
# packages: write # Required for pushing to GitHub Container Registry
inputs:
required_commands:
description: Space-separated list of required command-line tools
required: false
type: string
default: ''
required_python_packages:
description: Space-separated list of required Python packages
required: false
type: string
default: ''
env:
# Keep the commands and packages in lexicographical order.
REQUIRED_COMMANDS: >-
${{ inputs.required_commands != '' && inputs.required_commands || 'actionlint
ansible
docker
gh
make
node
npm
pip
pre-commit
python3
rg' }}
REQUIRED_PYTHON_PACKAGES: >-
${{ inputs.required_python_packages != '' && inputs.required_python_packages || 'ansible
ansible-lint
docker
molecule
pre-commit
uv' }}
workflow_dispatch:
permissions:
contents: read
packages: write
jobs:
devcontainer-build:
if: github.event_name != 'pull_request' || !github.event.pull_request.draft
name: Build & Test
permissions:
contents: read
packages: write # Enables push to GHCR
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Login to GitHub Container Registry
uses: docker/login-action@v4.2.0
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set image name
id: image
run: |
# Transform repository name to valid Docker tag format
# 1. Convert to lowercase (Docker tags must be lowercase)
# 2. Remove leading dots from path components (Docker components must start with alphanumeric)
REPO_NAME="${{ github.repository }}"
REPO_LOWER="${REPO_NAME,,}"
# Remove /. pattern to handle repos like "org/.github" -> "org/github"
SAFE_REPO_NAME="${REPO_LOWER//\/\./\/}"
echo "name=ghcr.io/${SAFE_REPO_NAME}/devcontainer" >> "$GITHUB_OUTPUT"
- name: Check cache image existence
id: cache_check
continue-on-error: true
run: |
IMAGE_NAME="${{ steps.image.outputs.name }}"
echo "Checking if cache image exists: ${IMAGE_NAME}:latest"
if docker pull "${IMAGE_NAME}:latest" 2>/dev/null; then
echo "✓ Cache image found: ${IMAGE_NAME}:latest"
echo "exists=true" >> "$GITHUB_OUTPUT"
else
echo "⚠ Cache image not found: ${IMAGE_NAME}:latest"
echo "⚠ Build will proceed without cache (first build or image expired)"
echo "exists=false" >> "$GITHUB_OUTPUT"
fi
- name: Build and test dev container
uses: devcontainers/ci@v0.3
with:
imageName: ${{ steps.image.outputs.name }}
cacheFrom: ${{ steps.image.outputs.name }}
push: filter
refFilterForPush: refs/heads/main
runCmd: |-
echo "Testing devcontainer build..."

# Check all required commands are installed
echo "Checking required command-line tools..."
for cmd in $REQUIRED_COMMANDS; do
if ! command -v "$cmd" &> /dev/null; then
echo "✗ $cmd is not installed"
exit 1
fi
echo "✓ $cmd is installed"
done

# Check all required Python packages are installed
echo "Checking required Python packages..."
for pkg in $REQUIRED_PYTHON_PACKAGES; do
if ! python3 -m pip show "$pkg" &> /dev/null; then
echo "✗ Required Python package '$pkg' is missing"
exit 1
fi
echo "✓ $pkg is installed"
done
echo "✓ All required Python packages are installed"

# Verify pre-commit can run (hooks may not be installed in CI container)
if pre-commit --version &> /dev/null; then
echo "✓ pre-commit is functional"
else
echo "✗ pre-commit is not functional"
exit 1
fi
echo "✓ All devcontainer tests passed!"
# See: https://docs.github.com/en/actions/how-tos/reuse-automations/reuse-workflows
uses: kenorb/.github/.github/workflows/devcontainer-ci.yml@main
secrets: inherit # pragma: allowlist secret
21 changes: 0 additions & 21 deletions .gitmodules

This file was deleted.

2 changes: 2 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"chat.tools.terminal.autoApprove": {
"git rev-parse": true,
"git submodule": true,
"locale": true,
"pipenv": true,
"pre-commit": true
Expand Down
1 change: 0 additions & 1 deletion bin
Submodule bin deleted from 176bbd
1 change: 0 additions & 1 deletion other/adamv
Submodule adamv deleted from f6a2ca
1 change: 0 additions & 1 deletion other/bsclifton
Submodule bsclifton deleted from 5e4349
1 change: 0 additions & 1 deletion other/cowboy
Submodule cowboy deleted from 4a2724
1 change: 0 additions & 1 deletion other/mathiasbynens
Submodule mathiasbynens deleted from b56936
Loading