Skip to content

Commit

Permalink
split the package into two modules (#50)
Browse files Browse the repository at this point in the history
  • Loading branch information
amtoine authored Oct 31, 2023
1 parent 8aec003 commit 2a2dfc0
Show file tree
Hide file tree
Showing 13 changed files with 12 additions and 8 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ in your `config.nu` you can add the following to load `nu-git-manager` modules:
use nu-git-manager *
# the following are non-essential modules
use nu-git-manager sugar git # augmnet Git with custom commands
use nu-git-manager sugar gh # load commands to interact with *GitHub*
use nu-git-manager sugar gist # load commands to interact with *GitHub* gists
use nu-git-manager-sugar git # augment Git with custom commands
use nu-git-manager-sugar gh # load commands to interact with *GitHub*
use nu-git-manager-sugar gist # load commands to interact with *GitHub* gists
```

then you have access to the whole `nu-git-manager` suite :partying_face:
Expand Down
4 changes: 4 additions & 0 deletions package.nuon
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,8 @@
}
}
type: "module"
modules: [
"./src/nu-git-manager/",
"./src/nu-git-manager-sugar/",
]
}
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use ../fs/dir.nu [open-item]
use fs/dir.nu [open-item]
def check-gh-logged-in [] {
let out = (do -i { gh auth status } | complete)
if $out.exit_code != 0 {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions tests/mod.nu
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
use std assert

use ../nu-git-manager/git/url.nu [parse-git-url, get-fetch-push-urls]
use ../nu-git-manager/fs/store.nu [get-repo-store-path, list-repos-in-store]
use ../nu-git-manager/fs/cache.nu [
use ../src/nu-git-manager/git/url.nu [parse-git-url, get-fetch-push-urls]
use ../src/nu-git-manager/fs/store.nu [get-repo-store-path, list-repos-in-store]
use ../src/nu-git-manager/fs/cache.nu [
get-repo-store-cache-path, check-cache-file, add-to-cache, remove-from-cache, open-cache,
save-cache, make-cache
]
use ../nu-git-manager/fs/path.nu "path sanitize"
use ../src/nu-git-manager/fs/path.nu "path sanitize"

export def path-sanitization [] {
assert equal ('\foo\bar' | path sanitize) "/foo/bar"
Expand Down

0 comments on commit 2a2dfc0

Please sign in to comment.