mirror of
https://github.com/affaan-m/ECC.git
synced 2026-08-29 03:09:38 +02:00
fix(release): clear final review blockers
This commit is contained in:
@@ -199,6 +199,6 @@ jobs:
|
||||
uses: softprops/action-gh-release@3d0d9888cb7fd7b750713d6e236d1fcb99157228 # v3.0.2
|
||||
with:
|
||||
body_path: release_body.md
|
||||
generate_release_notes: true
|
||||
generate_release_notes: false
|
||||
prerelease: ${{ contains(github.ref_name, '-') }}
|
||||
make_latest: ${{ contains(github.ref_name, '-') && 'false' || 'true' }}
|
||||
|
||||
@@ -7,11 +7,6 @@ on:
|
||||
description: 'Version tag (e.g., v1.0.0)'
|
||||
required: true
|
||||
type: string
|
||||
generate-notes:
|
||||
description: 'Auto-generate release notes'
|
||||
required: false
|
||||
type: boolean
|
||||
default: true
|
||||
secrets:
|
||||
NPM_TOKEN:
|
||||
required: false
|
||||
@@ -21,11 +16,6 @@ on:
|
||||
description: 'Version tag to release or republish (e.g., v2.0.0-rc.1)'
|
||||
required: true
|
||||
type: string
|
||||
generate-notes:
|
||||
description: 'Auto-generate release notes'
|
||||
required: false
|
||||
type: boolean
|
||||
default: true
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
@@ -224,6 +214,6 @@ jobs:
|
||||
with:
|
||||
tag_name: ${{ inputs.tag }}
|
||||
body_path: release_body.md
|
||||
generate_release_notes: ${{ inputs.generate-notes }}
|
||||
generate_release_notes: false
|
||||
prerelease: ${{ contains(inputs.tag, '-') }}
|
||||
make_latest: ${{ contains(inputs.tag, '-') && 'false' || 'true' }}
|
||||
|
||||
@@ -39,7 +39,7 @@ Targets:
|
||||
antigravity - Install rules, workflows, skills, and agents to ./.agents/
|
||||
codex - Install shared agents/config into ~/.codex/
|
||||
gemini - Install project-local Gemini config into ./.gemini/
|
||||
opencode - Install shared commands/hooks/config into ~/.config/opencode/
|
||||
opencode - Install into OPENCODE_CONFIG_DIR, XDG_CONFIG_HOME/opencode, or ~/.config/opencode/
|
||||
codebuddy - Install commands, agents, skills, and flattened rules into ./.codebuddy/
|
||||
joycode - Install commands, agents, skills, and flattened rules into ./.joycode/
|
||||
qwen - Install commands, agents, skills, rules, and Qwen config into ~/.qwen/
|
||||
|
||||
@@ -136,6 +136,7 @@ const HARNESS_CAPABILITIES = deepFreeze([
|
||||
guidedReady: false,
|
||||
availability: 'advanced',
|
||||
destination: '~/.config/opencode',
|
||||
destinationResolution: 'OPENCODE_CONFIG_DIR, then XDG_CONFIG_HOME/opencode, then ~/.config/opencode',
|
||||
scopes: [scope('home', 'opencode', '~/.config/opencode')],
|
||||
hooks: hooks(
|
||||
'adapter-opt-in',
|
||||
@@ -249,7 +250,7 @@ for (const harness of HARNESS_CAPABILITIES) {
|
||||
function expectedRootForAdapter(adapter) {
|
||||
const homeDir = path.resolve('/__ecc_catalog_home__');
|
||||
const projectRoot = path.resolve('/__ecc_catalog_project__');
|
||||
const absoluteRoot = adapter.resolveRoot({ homeDir, projectRoot });
|
||||
const absoluteRoot = adapter.resolveRoot({ homeDir, projectRoot, env: {} });
|
||||
const baseRoot = adapter.kind === 'home' ? homeDir : projectRoot;
|
||||
const prefix = adapter.kind === 'home' ? '~/' : './';
|
||||
return `${prefix}${path.relative(baseRoot, absoluteRoot).replace(/\\/g, '/')}`;
|
||||
|
||||
@@ -264,6 +264,9 @@ function createInstallTargetAdapter(config) {
|
||||
},
|
||||
resolveRoot(input = {}) {
|
||||
const baseRoot = resolveBaseRoot(config.kind, input);
|
||||
if (typeof config.resolveRoot === 'function') {
|
||||
return config.resolveRoot(input, baseRoot);
|
||||
}
|
||||
return path.join(baseRoot, ...config.rootSegments);
|
||||
},
|
||||
getInstallStatePath(input = {}) {
|
||||
|
||||
@@ -6,6 +6,7 @@ const {
|
||||
buildValidationIssue,
|
||||
createInstallTargetAdapter,
|
||||
} = require('./helpers');
|
||||
const { resolveOpencodeConfigRoot } = require('../opencode-paths');
|
||||
|
||||
const COMPILED_PLUGIN_DIST_DIR = path.join('.opencode', 'dist');
|
||||
const REQUIRED_COMPILED_ARTEFACTS = Object.freeze([
|
||||
@@ -84,6 +85,7 @@ module.exports = createInstallTargetAdapter({
|
||||
target: 'opencode',
|
||||
kind: 'home',
|
||||
rootSegments: ['.config', 'opencode'],
|
||||
resolveRoot: resolveOpencodeConfigRoot,
|
||||
installStatePathSegments: ['ecc-install-state.json'],
|
||||
nativeRootRelativePath: '.opencode',
|
||||
validate: defaultValidateOpencodeHome,
|
||||
|
||||
@@ -52,6 +52,7 @@ function planInstallTargetScaffold(options = {}) {
|
||||
repoRoot: options.repoRoot,
|
||||
projectRoot: options.projectRoot || options.repoRoot,
|
||||
homeDir: options.homeDir,
|
||||
env: options.env || process.env,
|
||||
};
|
||||
const validationIssues = adapter.validate(planningInput);
|
||||
const blockingIssues = validationIssues.filter(issue => (
|
||||
|
||||
@@ -120,12 +120,25 @@ function readInstalledFileNoFollow(plan, operation) {
|
||||
}
|
||||
|
||||
function stateWithContentDigests(state, plan) {
|
||||
const currentDestinations = new Set((plan.operations || [])
|
||||
.filter(operation => operation.destinationPath)
|
||||
.map(operation => {
|
||||
const resolved = path.resolve(operation.destinationPath);
|
||||
return process.platform === 'win32' ? resolved.toLowerCase() : resolved;
|
||||
}));
|
||||
return {
|
||||
...state,
|
||||
operations: (state.operations || []).map(operation => {
|
||||
if (!operation.destinationPath) {
|
||||
return { ...operation };
|
||||
}
|
||||
const resolved = path.resolve(operation.destinationPath);
|
||||
const destinationKey = process.platform === 'win32'
|
||||
? resolved.toLowerCase()
|
||||
: resolved;
|
||||
if (!currentDestinations.has(destinationKey)) {
|
||||
return { ...operation };
|
||||
}
|
||||
const installedContent = readInstalledFileNoFollow(plan, operation);
|
||||
if (installedContent === null) {
|
||||
return { ...operation };
|
||||
|
||||
@@ -243,7 +243,7 @@ function createDisabledMigration(plan, previousState) {
|
||||
bridgeState: finalState,
|
||||
finalState,
|
||||
legacyOperationsToRemove: [],
|
||||
requiresBridgeState: false,
|
||||
requiresBridgeState: plan.operations.length > 0,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -3,8 +3,9 @@
|
||||
const fs = require('fs');
|
||||
const os = require('os');
|
||||
const path = require('path');
|
||||
const { resolveOpencodeConfigRoot } = require('../../opencode-paths');
|
||||
|
||||
// OpenCode stores MCP servers under "mcp" in ~/.config/opencode/opencode.json.
|
||||
// OpenCode stores MCP servers under "mcp" in its resolved configuration root.
|
||||
// Shape differs from Claude/Codex:
|
||||
// { type: "local"|"remote", command: ["npx","-y","pkg"], environment: {},
|
||||
// enabled: bool, url: "https://..." }
|
||||
@@ -38,11 +39,12 @@ function mapOpencodeServer(name, raw, configPath) {
|
||||
|
||||
function readOpencodeMcp(options = {}) {
|
||||
const homeDir = options.homeDir || os.homedir();
|
||||
const configRoot = resolveOpencodeConfigRoot({ homeDir, env: options.env });
|
||||
const candidatePaths = options.configPath
|
||||
? [options.configPath]
|
||||
: [
|
||||
path.join(homeDir, '.config', 'opencode', 'opencode.json'),
|
||||
path.join(homeDir, '.config', 'opencode', 'config.json'),
|
||||
path.join(configRoot, 'opencode.json'),
|
||||
path.join(configRoot, 'config.json'),
|
||||
path.join(homeDir, '.opencode.json')
|
||||
];
|
||||
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
'use strict';
|
||||
|
||||
const os = require('os');
|
||||
const path = require('path');
|
||||
|
||||
function configuredDirectory(environment, name) {
|
||||
const value = environment && environment[name];
|
||||
return typeof value === 'string' && value.trim() !== ''
|
||||
? path.resolve(value.trim())
|
||||
: null;
|
||||
}
|
||||
|
||||
function resolveOpencodeConfigRoot(options = {}) {
|
||||
const environment = options.env || process.env;
|
||||
const explicitRoot = configuredDirectory(environment, 'OPENCODE_CONFIG_DIR');
|
||||
if (explicitRoot) {
|
||||
return explicitRoot;
|
||||
}
|
||||
|
||||
const xdgConfigRoot = configuredDirectory(environment, 'XDG_CONFIG_HOME');
|
||||
if (xdgConfigRoot) {
|
||||
return path.join(xdgConfigRoot, 'opencode');
|
||||
}
|
||||
|
||||
return path.join(path.resolve(options.homeDir || os.homedir()), '.config', 'opencode');
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
resolveOpencodeConfigRoot,
|
||||
};
|
||||
Reference in New Issue
Block a user