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
11 changes: 11 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
"description": "Set up repositories for AI-assisted development",
"main": "dist/index.js",
"type": "module",
"workspaces": [
"packages/*"
],
"bin": {
"agentrc": "dist/index.js"
},
Expand Down
12 changes: 12 additions & 0 deletions packages/core/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"name": "@agentrc/core",
"version": "2.0.0",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts",
"./config": "./src/config.ts",
"./services/*": "./src/services/*.ts",
"./utils/*": "./src/utils/*.ts"
}
}
File renamed without changes.
133 changes: 133 additions & 0 deletions packages/core/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
// @agentrc/core barrel — re-exports all public API surface

// Config
export { DEFAULT_MODEL, DEFAULT_JUDGE_MODEL } from "./config";

// Services
export {
analyzeRepo,
detectWorkspaces,
loadAgentrcConfig,
sanitizeAreaName
} from "./services/analyzer";
export type {
RepoApp,
Area,
RepoAnalysis,
InstructionStrategy,
AgentrcConfig,
AgentrcConfigArea,
AgentrcConfigWorkspace
} from "./services/analyzer";

export {
createPullRequest as createAzurePullRequest,
getRepo as getAzureDevOpsRepo
} from "./services/azureDevops";

export {
processGitHubRepo,
processAzureRepo,
runBatchHeadlessGitHub,
runBatchHeadlessAzure,
processBatchReadinessRepo,
sanitizeError
} from "./services/batch";

export {
assertCopilotCliReady,
listCopilotModels,
buildExecArgs,
logCopilotDebug
} from "./services/copilot";
export type { CopilotCliConfig } from "./services/copilot";

export {
loadCopilotSdk,
createCopilotClient,
attachDefaultPermissionHandler
} from "./services/copilotSdk";

export { generateEvalScaffold } from "./services/evalScaffold";

export { runEval } from "./services/evaluator";

export { generateConfigs } from "./services/generator";
export type { FileAction, GenerateResult, GenerateOptions } from "./services/generator";

export {
isGitRepo,
cloneRepo,
setRemoteUrl,
checkoutBranch,
commitAll,
buildAuthedUrl,
pushBranch
} from "./services/git";

export {
getGitHubToken,
createGitHubClient,
listAccessibleRepos,
getRepo as getGitHubRepo,
createPullRequest,
listUserOrgs,
listOrgRepos,
checkRepoHasInstructions,
checkReposForInstructions
} from "./services/github";
export type { GitHubRepo, GitHubOrg } from "./services/github";

export {
generateCopilotInstructions,
generateAreaInstructions,
generateNestedInstructions,
generateNestedAreaInstructions,
writeAreaInstruction,
writeNestedInstructions,
detectExistingInstructions,
buildExistingInstructionsSection
} from "./services/instructions";

export { parsePolicySources, loadPolicy, resolveChain } from "./services/policy";

export {
runReadinessReport,
groupPillars,
getLevelName,
getLevelDescription,
buildCriteria
} from "./services/readiness";
export type {
ReadinessReport,
ReadinessCriterionResult,
ReadinessExtraResult
} from "./services/readiness";

export { generateVisualReport } from "./services/visualReport";

// Utils
export {
ensureDir,
safeWriteFile,
validateCachePath,
fileExists,
safeReadDir,
readJson,
buildTimestampedName
} from "./utils/fs";
export type { WriteResult } from "./utils/fs";

export { prettyPrintSummary } from "./utils/logger";

export {
createProgressReporter,
shouldLog,
outputResult,
deriveFileStatus,
outputError
} from "./utils/output";
export type { CommandResult, ProgressReporter } from "./utils/output";

export { isAgentrcFile, buildInstructionsPrBody, buildFullPrBody } from "./utils/pr";
export { GITHUB_REPO_RE, AZURE_REPO_RE } from "./utils/repo";
File renamed without changes.
Loading