@ridit/forge 0.2.8 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Forge
2
2
 
3
- > Git, but yours.
3
+ Git, but yours.
4
4
 
5
5
  Forge is a lightweight version control system built from scratch. Designed to be simple and easy to understand — Forge gives you the core of a VCS without the complexity of Git.
6
6
 
package/dist/index.mjs CHANGED
@@ -44210,7 +44210,9 @@ function createBranch(repo_path, branch_name) {
44210
44210
  const branch = currentBranch.branch;
44211
44211
  const commitsFolder = path7.join(repo_path, ".forge", "branches", branch.name, "commits");
44212
44212
  const newBranchCommitsFolder = path7.join(repo_path, ".forge", "branches", branch_name, "commits");
44213
- fs9.cpSync(commitsFolder, newBranchCommitsFolder, { recursive: true });
44213
+ try {
44214
+ fs9.cpSync(commitsFolder, newBranchCommitsFolder, { recursive: true });
44215
+ } catch {}
44214
44216
  fs9.writeFileSync(branchDataFile, JSON.stringify({
44215
44217
  name: branch_name,
44216
44218
  latestCommitId: branch.latestCommitId
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ridit/forge",
3
- "version": "0.2.8",
3
+ "version": "0.3.0",
4
4
  "description": "Git, but yours.",
5
5
  "author": "Ridit Jangra <riditjangra09@gmail.com> (https://ridit.space)",
6
6
  "license": "MIT",
@@ -68,7 +68,9 @@ export function createBranch(
68
68
  "commits",
69
69
  );
70
70
 
71
- fs.cpSync(commitsFolder, newBranchCommitsFolder, { recursive: true });
71
+ try {
72
+ fs.cpSync(commitsFolder, newBranchCommitsFolder, { recursive: true });
73
+ } catch {}
72
74
 
73
75
  fs.writeFileSync(
74
76
  branchDataFile!,