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
2 changes: 1 addition & 1 deletion src/app/api/native/git/branches/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ async function handlePublish(branchName: string, localTaxonomyDir: string, remot
return NextResponse.json({ error: 'Invalid contribution name for publish' }, { status: 400 });
}

console.log(`Publishing contribution from ${branchName} to remote taxonomy repo at ${REMOTE_TAXONOMY_ROOT_DIR}/taxonomy`);
console.log(`Publishing contribution from ${branchName} to remote taxonomy repo at ${remoteTaxonomyDir}`);
const changes = await findDiff(branchName, localTaxonomyDir);

// Check if there are any changes to publish, create a new branch at remoteTaxonomyDir and
Expand Down
4 changes: 2 additions & 2 deletions src/app/api/native/tree/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ export async function POST(req: NextRequest) {
const taxonomyRootPath = findTaxonomyRepoPath();
let dirPath = '';
if (root_path === 'skills') {
dirPath = path.join(taxonomyRootPath, 'taxonomy', SKILLS, dir_name);
dirPath = path.join(taxonomyRootPath, SKILLS, dir_name);
} else {
dirPath = path.join(taxonomyRootPath, 'taxonomy', KNOWLEDGE, dir_name);
dirPath = path.join(taxonomyRootPath, KNOWLEDGE, dir_name);
}
const dirs = getFirstLevelDirectories(dirPath);
return NextResponse.json({ data: dirs }, { status: 201 });
Expand Down
2 changes: 1 addition & 1 deletion src/app/api/native/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,5 @@ export const findTaxonomyRepoPath = (): string => {
if (remoteTaxonomyRepoDirFinal === '') {
return '';
}
return remoteTaxonomyRepoDirFinal;
return path.join(remoteTaxonomyRepoDirFinal, '/taxonomy');
};