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
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ repos:
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-yaml
exclude: 'adbc_drivers_dev/templates/.*\.yaml'
- id: detect-private-key
- id: end-of-file-fixer
- id: mixed-line-ending
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@
include adbc_drivers_dev/.env
include adbc_drivers_dev/compose.yaml
recursive-include adbc_drivers_dev/compose/ Dockerfile *.ld *.sh
recursive-include adbc_drivers_dev/templates/ *.yaml
75 changes: 75 additions & 0 deletions adbc_drivers_dev/templates/dev.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
<% if private %>
# Copyright (c) 2025 Columnar Technologies Inc. All rights reserved.
<% else %>
# Copyright (c) 2025 ADBC Drivers Contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
<% endif %>

# This is a common workflow for performing basic PR checks like running
# pre-commit.

name: Dev

on:
pull_request: {}
push:
branches:
- main

concurrency:
group: ${{ github.repository }}-${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true

defaults:
run:
shell: bash

permissions:
contents: read

jobs:
lint:
name: "lint & pre-commit"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
fetch-depth: 0
persist-credentials: false

<% if lang.get("go") %>
- uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
with:
cache-dependency-path: go/go.sum
check-latest: true
go-version-file: go/go.mod
<% endif %>

- uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
with:
python-version: "3.x"

- name: Install
run: pip install pre-commit

- name: pre-commit (cache)
uses: actions/cache@9255dc7a253b0ccc959486e2bca901246202afeb # v5.0.1
with:
path: ~/.cache/pre-commit
key: pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}

- name: pre-commit
run: |
pre-commit run --all-files --color=always --show-diff-on-failure --verbose
47 changes: 47 additions & 0 deletions adbc_drivers_dev/templates/dev_issues.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<% if private %>
# Copyright (c) 2025 Columnar Technologies Inc. All rights reserved.
<% else %>
# Copyright (c) 2025 ADBC Drivers Contributors
<% endif %>
#
# This file has been modified from its original version, which is
# under the Apache License:
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: Issues Bot

on:
issue_comment:
types:
- created
- edited

jobs:
issue_assign:
name: "Assign issue"
permissions:
issues: write
if: github.event.comment.body == 'take'
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
github.rest.issues.addAssignees({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.payload.issue.number,
assignees: context.payload.comment.user.login
});
71 changes: 71 additions & 0 deletions adbc_drivers_dev/templates/dev_pr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
<% if private %>
# Copyright (c) 2025 Columnar Technologies Inc. All rights reserved.
<% else %>
# Copyright (c) 2025 ADBC Drivers Contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
<% endif %>

# This is a common workflow for performing basic PR checks, like ensuring the
# title format.

name: Dev PR

on:
pull_request_target:
types:
- opened
- edited
- synchronize
- ready_for_review
- review_requested

concurrency:
group: ${{ github.repository }}-${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true

defaults:
run:
shell: bash

permissions:
contents: read

jobs:
pr_standard:
name: "Check PR"
runs-on: ubuntu-latest
if: github.event_name == 'pull_request'

steps:
<% if driver == "dev" %>
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
fetch-depth: 1
persist-credentials: false

- name: Check PR title format
env:
PR_TITLE: ${{ github.event.pull_request.title }}
run: |
python adbc_drivers_dev/title_check.py $(pwd) "$PR_TITLE"
<% else %>
- name: Check PR title format
env:
PR_TITLE: ${{ github.event.pull_request.title }}
run: |
git clone --depth 1 https://github.com/adbc-drivers/dev
python dev/adbc_drivers_dev/title_check.py $(pwd) "$PR_TITLE"
<% endif %>

# TODO: assign milestone
Loading