Skip to content

Commit 5b5b4a5

Browse files
authored
Merge branch 'dev' into fix/lsp-error-message-improvement
2 parents 1c369b1 + d9d43d8 commit 5b5b4a5

647 files changed

Lines changed: 40115 additions & 12309 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/close-prs.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: close-prs
2+
3+
on:
4+
schedule:
5+
- cron: "0 22 * * *" # Daily at 10:00 PM UTC
6+
workflow_dispatch:
7+
inputs:
8+
dry-run:
9+
description: "Log matching PRs without closing them"
10+
type: boolean
11+
default: true
12+
max-close:
13+
description: "Maximum matching PRs to close"
14+
type: string
15+
required: false
16+
default: "50"
17+
18+
jobs:
19+
close:
20+
runs-on: ubuntu-latest
21+
timeout-minutes: 240
22+
permissions:
23+
contents: read
24+
issues: write
25+
pull-requests: write
26+
steps:
27+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
28+
29+
- uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0
30+
with:
31+
bun-version: latest
32+
33+
- name: Close old PRs without enough positive reactions
34+
env:
35+
GITHUB_TOKEN: ${{ github.token }}
36+
run: |
37+
max_close="${{ inputs['max-close'] }}"
38+
if [ -z "$max_close" ]; then
39+
max_close="50"
40+
fi
41+
42+
args=("--threshold" "2" "--age-months" "1" "--sleep-ms" "20000" "--max-close" "$max_close")
43+
44+
if [ "${{ github.event_name }}" = "schedule" ]; then
45+
args+=("--execute")
46+
elif [ "${{ inputs['dry-run'] }}" = "false" ]; then
47+
args+=("--execute")
48+
fi
49+
50+
bun script/github/close-prs.ts "${args[@]}"

.github/workflows/close-stale-prs.yml

Lines changed: 0 additions & 235 deletions
This file was deleted.

.github/workflows/publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77
- ci
88
- dev
99
- beta
10+
- fix/npm-native-binary-install
1011
- snapshot-*
1112
workflow_dispatch:
1213
inputs:

AGENTS.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,29 @@ function foo() {
7373
}
7474
```
7575

76+
### Complex Logic
77+
78+
When a function has several validation branches or supporting details, make the main function read as the happy path and move supporting details into small helpers below it.
79+
80+
```ts
81+
// Good
82+
export function loadThing(input: unknown) {
83+
const config = requireConfig(input)
84+
const metadata = readMetadata(input)
85+
return createThing({ config, metadata })
86+
}
87+
88+
function requireConfig(input: unknown) {
89+
...
90+
}
91+
```
92+
93+
- Keep helpers close to the code they support, below the main export when that improves readability.
94+
- Do not over-abstract simple expressions into many single-use helpers; extract only when it names a real concept like `requireConfig` or `readMetadata`.
95+
- Do not return `Effect` from helpers unless they actually perform effectful work. Synchronous parsing, validation, and option building should stay synchronous.
96+
- Prefer Effect schema helpers such as `Schema.UnknownFromJsonString` and `Schema.decodeUnknownOption` over manual `JSON.parse` wrapped in `Effect.try` when parsing untrusted JSON strings.
97+
- Add comments for non-obvious constraints and surprising behavior, not for obvious assignments or control flow.
98+
7699
### Schema Definitions (Drizzle)
77100

78101
Use snake_case for field names so column names don't need to be redefined as strings.

README.ar.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -124,18 +124,6 @@ XDG_BIN_DIR=$HOME/.local/bin curl -fsSL https://opencode.ai/install | bash
124124

125125
اذا كنت تعمل على مشروع مرتبط بـ OpenCode ويستخدم "opencode" كجزء من اسمه (مثل "opencode-dashboard" او "opencode-mobile")، يرجى اضافة ملاحظة في README توضح انه ليس مبنيا بواسطة فريق OpenCode ولا يرتبط بنا بأي شكل.
126126

127-
### FAQ
128-
129-
#### ما الفرق عن Claude Code؟
130-
131-
هو مشابه جدا لـ Claude Code من حيث القدرات. هذه هي الفروقات الاساسية:
132-
133-
- 100% مفتوح المصدر
134-
- غير مقترن بمزود معين. نوصي بالنماذج التي نوفرها عبر [OpenCode Zen](https://opencode.ai/zen)؛ لكن يمكن استخدام OpenCode مع Claude او OpenAI او Google او حتى نماذج محلية. مع تطور النماذج ستتقلص الفجوات وستنخفض الاسعار، لذا من المهم ان يكون مستقلا عن المزود.
135-
- دعم LSP جاهز للاستخدام
136-
- تركيز على TUI. تم بناء OpenCode بواسطة مستخدمي neovim ومنشئي [terminal.shop](https://terminal.shop)؛ وسندفع حدود ما هو ممكن داخل الطرفية.
137-
- معمارية عميل/خادم. على سبيل المثال، يمكن تشغيل OpenCode على جهازك بينما تقوده عن بعد من تطبيق جوال. هذا يعني ان واجهة TUI هي واحدة فقط من العملاء الممكنين.
138-
139127
---
140128

141129
**انضم الى مجتمعنا** [Discord](https://discord.gg/opencode) | [X.com](https://x.com/opencode)

README.bn.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -124,18 +124,6 @@ OpenCode এ দুটি বিল্ট-ইন এজেন্ট রয়ে
124124

125125
আপনি যদি এমন প্রজেক্টে কাজ করেন যা OpenCode এর সাথে সম্পর্কিত এবং প্রজেক্টের নামের অংশ হিসেবে "opencode" ব্যবহার করেন, উদাহরণস্বরূপ "opencode-dashboard" বা "opencode-mobile", তবে দয়া করে আপনার README তে একটি নোট যোগ করে স্পষ্ট করুন যে এই প্রজেক্টটি OpenCode দল দ্বারা তৈরি হয়নি এবং আমাদের সাথে এর কোনো সরাসরি সম্পর্ক নেই।
126126

127-
### সচরাচর জিজ্ঞাসিত প্রশ্নাবলী (FAQ)
128-
129-
#### এটি ক্লড কোড (Claude Code) থেকে কীভাবে আলাদা?
130-
131-
ক্যাপাবিলিটির দিক থেকে এটি ক্লড কোডের (Claude Code) মতই। এখানে মূল পার্থক্যগুলো দেওয়া হলো:
132-
133-
- ১০০% ওপেন সোর্স
134-
- কোনো প্রোভাইডারের সাথে আবদ্ধ নয়। যদিও আমরা [OpenCode Zen](https://opencode.ai/zen) এর মাধ্যমে মডেলসমূহ ব্যবহারের পরামর্শ দিই, OpenCode ক্লড (Claude), ওপেনএআই (OpenAI), গুগল (Google), অথবা লোকাল মডেলগুলোর সাথেও ব্যবহার করা যেতে পারে। যেমন যেমন মডেলগুলো উন্নত হবে, তাদের মধ্যকার পার্থক্য কমে আসবে এবং দামও কমবে, তাই প্রোভাইডার-অজ্ঞাস্টিক হওয়া খুবই গুরুত্বপূর্ণ।
135-
- আউট-অফ-দ্য-বক্স LSP সাপোর্ট
136-
- TUI এর উপর ফোকাস। OpenCode নিওভিম (neovim) ব্যবহারকারী এবং [terminal.shop](https://terminal.shop) এর নির্মাতাদের দ্বারা তৈরি; আমরা টার্মিনালে কী কী সম্ভব তার সীমাবদ্ধতা ছাড়িয়ে যাওয়ার চেষ্টা করছি।
137-
- ক্লায়েন্ট/সার্ভার আর্কিটেকচার। এটি যেমন OpenCode কে আপনার কম্পিউটারে চালানোর সুযোগ দেয়, তেমনি আপনি মোবাইল অ্যাপ থেকে রিমোটলি এটি নিয়ন্ত্রণ করতে পারবেন, অর্থাৎ TUI ফ্রন্টএন্ড কেবল সম্ভাব্য ক্লায়েন্টগুলোর মধ্যে একটি।
138-
139127
---
140128

141129
**আমাদের কমিউনিটিতে যুক্ত হোন** [Discord](https://discord.gg/opencode) | [X.com](https://x.com/opencode)

README.br.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -124,18 +124,6 @@ Se você tem interesse em contribuir com o OpenCode, leia os [contributing docs]
124124

125125
Se você estiver trabalhando em um projeto relacionado ao OpenCode e estiver usando "opencode" como parte do nome (por exemplo, "opencode-dashboard" ou "opencode-mobile"), adicione uma nota no README para deixar claro que não foi construído pela equipe do OpenCode e não é afiliado a nós de nenhuma forma.
126126

127-
### FAQ
128-
129-
#### Como isso é diferente do Claude Code?
130-
131-
É muito parecido com o Claude Code em termos de capacidade. Aqui estão as principais diferenças:
132-
133-
- 100% open source
134-
- Não está acoplado a nenhum provedor. Embora recomendemos os modelos que oferecemos pelo [OpenCode Zen](https://opencode.ai/zen); o OpenCode pode ser usado com Claude, OpenAI, Google ou até modelos locais. À medida que os modelos evoluem, as diferenças diminuem e os preços caem, então ser provider-agnostic é importante.
135-
- Suporte a LSP pronto para uso
136-
- Foco em TUI. O OpenCode é construído por usuários de neovim e pelos criadores do [terminal.shop](https://terminal.shop); vamos levar ao limite o que é possível no terminal.
137-
- Arquitetura cliente/servidor. Isso, por exemplo, permite executar o OpenCode no seu computador enquanto você o controla remotamente por um aplicativo mobile. Isso significa que o frontend TUI é apenas um dos possíveis clientes.
138-
139127
---
140128

141129
**Junte-se à nossa comunidade** [Discord](https://discord.gg/opencode) | [X.com](https://x.com/opencode)

0 commit comments

Comments
 (0)