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
4 changes: 2 additions & 2 deletions nupm/publish.nu
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ export def main [
}
}

def guess-url [] -> string {
def guess-url []: nothing -> string {
mut url = (do -i { ^git remote get-url origin | complete } | get stdout)

if ($url | is-empty) {
Expand All @@ -191,7 +191,7 @@ def guess-url [] -> string {
$url | str trim
}

def guess-revision [] -> string {
def guess-revision []: nothing -> string {
mut revision = (do -i { ^git describe --tags --abbrev=0 | complete }
| get stdout)

Expand Down
2 changes: 1 addition & 1 deletion nupm/status.nu
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use utils/package.nu [open-package-file list-package-files]
# Display status of a package
export def main [
path?: path # path to the package
] -> record<filename: string> {
]: nothing -> record<filename: string> {
let path = $path | default $env.PWD | path expand

let pkg = open-package-file $path
Expand Down
2 changes: 1 addition & 1 deletion nupm/utils/package.nu
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export def open-package-file [dir: path] {
# Lists files of a package
#
# This will be useful for file integrity checks
export def list-package-files [pkg_dir: path, pkg: record] -> list<path> {
export def list-package-files [pkg_dir: path, pkg: record]: nothing -> list<path> {
let activation = match $pkg.type {
'module' => $'use ($pkg.name)'
'script' => {
Expand Down
2 changes: 1 addition & 1 deletion nupm/utils/registry.nu
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export def search-package [
package: string # Name of the package
--registry: string # Which registry to use (name or path)
--exact-match # Searched package name must match exactly
] -> table {
]: nothing -> table {
let registries = if (not ($registry | is-empty)) and ($registry in $env.NUPM_REGISTRIES) {
# If $registry is a valid column in $env.NUPM_REGISTRIES, use that
{ $registry : ($env.NUPM_REGISTRIES | get $registry) }
Expand Down