diff --git a/packages/parser/package.json b/packages/parser/package.json index d14faf0..839b3e3 100644 --- a/packages/parser/package.json +++ b/packages/parser/package.json @@ -1,7 +1,7 @@ { "name": "@packwizjs/parser", "module": "src/index.ts", - "version": "1.1.2", + "version": "1.2.0", "type": "module", "description": "A simple library for parsing Packwiz TOML files", "author": { diff --git a/packages/parser/src/resource.ts b/packages/parser/src/resource.ts index 0b73cc3..6911166 100644 --- a/packages/parser/src/resource.ts +++ b/packages/parser/src/resource.ts @@ -155,4 +155,12 @@ export class Resource { } return new Resource(path.join(this.path, ...segments)); } + + /** + * Creates a new Resource instance with the current working directory. + * @returns A new Resource instance with the current working directory. + */ + static cwd(): Resource { + return new Resource(process.cwd()); + } }