From 7dcde8bcebd21620e6fc9bcaf0e5cb26da220362 Mon Sep 17 00:00:00 2001 From: Qiheng He Date: Tue, 3 Nov 2026 09:14:42 +0800 Subject: [PATCH 1/2] chore: add an `opencode.json` that allows `git push`, `gh pr create` and `gh pr comment` in this project --- opencode.json | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 opencode.json diff --git a/opencode.json b/opencode.json new file mode 100644 index 0000000..1402a1e --- /dev/null +++ b/opencode.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://opencode.ai/config.json", + "permissions": [ + { "action": "shell", "resource": "git push *", "effect": "allow" }, + { "action": "shell", "resource": "gh pr create *", "effect": "allow" }, + { "action": "shell", "resource": "gh pr comment *", "effect": "allow" } + ] +} From 980570e8fe495a4ba0144fc03cf0b5c903560b17 Mon Sep 17 00:00:00 2001 From: Qiheng He Date: Tue, 3 Nov 2026 09:20:30 +0800 Subject: [PATCH 2/2] chore: rename `opencode.json` to `opencode.jsonc` so that the license header check covers it --- opencode.json | 8 -------- opencode.jsonc | 24 ++++++++++++++++++++++++ 2 files changed, 24 insertions(+), 8 deletions(-) delete mode 100644 opencode.json create mode 100644 opencode.jsonc diff --git a/opencode.json b/opencode.json deleted file mode 100644 index 1402a1e..0000000 --- a/opencode.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "$schema": "https://opencode.ai/config.json", - "permissions": [ - { "action": "shell", "resource": "git push *", "effect": "allow" }, - { "action": "shell", "resource": "gh pr create *", "effect": "allow" }, - { "action": "shell", "resource": "gh pr comment *", "effect": "allow" } - ] -} diff --git a/opencode.jsonc b/opencode.jsonc new file mode 100644 index 0000000..3d46d87 --- /dev/null +++ b/opencode.jsonc @@ -0,0 +1,24 @@ +/* + * Copyright 2026 Han Li and 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. + */ + +{ + "$schema": "https://opencode.ai/config.json", + "permissions": [ + { "action": "shell", "resource": "git push *", "effect": "allow" }, + { "action": "shell", "resource": "gh pr create *", "effect": "allow" }, + { "action": "shell", "resource": "gh pr comment *", "effect": "allow" } + ] +}