Skip to content

Commit

Permalink
chore: version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
gokceno committed Apr 2, 2024
1 parent 0eece16 commit 5747b3d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 7 deletions.
2 changes: 1 addition & 1 deletion apps/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"@gokceno/crux-locales": "0.0.2",
"@gokceno/crux-bucket": "1.2.0",
"@gokceno/crux-bucket-cache-libsql": "0.3.10",
"@gokceno/crux-bucket-source-filesystem": "0.1.0",
"@gokceno/crux-bucket-source-filesystem": "0.1.1",
"@gokceno/crux-bucket-source-github": "0.1.0"
}
}
6 changes: 6 additions & 0 deletions packages/bucket-source-filesystem/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @gokceno/crux-bucket-source-filesystem

## 0.1.1

### Patch Changes

- Fixed locale paths.

## 0.1.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/bucket-source-filesystem/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gokceno/crux-bucket-source-filesystem",
"repository": "git+https://github.com/gokceno/crux.md.git",
"version": "0.1.0",
"version": "0.1.1",
"main": "./src/Filesystem.js",
"type": "module",
"publishConfig": {
Expand Down
12 changes: 7 additions & 5 deletions packages/bucket-source-filesystem/src/Filesystem.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,21 @@ export const FileSystem = ({ bucketPath }) => {
}
const _constructPath = ({ root, collection, single, filename, locale }) => {
let language, country;
let fragments = [];
if(root !== undefined) fragments.push(root);
if(locale !== undefined) {
// eslint-disable-next-line no-unused-vars
[language, country] = locale.split('-');
fragments.push(language);
}
let fragments = [];
if(root !== undefined) fragments.push(root);
if(collection !== undefined) {
fragments.push('collections', collection);
if (filename !== undefined) fragments.push(filename);
if(language) fragments.push(language);
if(filename !== undefined) fragments.push(filename);
}
else if(single !== undefined) {
fragments.push('singles', [single, _defaultFileExtension].join('.'));
fragments.push('singles');
if(language) fragments.push(language);
fragments.push([single, _defaultFileExtension].join('.'));
}
else {
throw new Error('Misformed file path.')
Expand Down

0 comments on commit 5747b3d

Please sign in to comment.