s
This commit is contained in:
4
plugins/clipboard.nu
Normal file
4
plugins/clipboard.nu
Normal file
@@ -0,0 +1,4 @@
|
||||
cargo install nu_plugin_clipboard
|
||||
register ~/.cargo/bin/nu_plugin_clipboard
|
||||
|
||||
# DOESNT WORK
|
10
plugins/dns.nu
Normal file
10
plugins/dns.nu
Normal file
@@ -0,0 +1,10 @@
|
||||
|
||||
|
||||
# https://github.com/dead10ck/nu_plugin_dns
|
||||
|
||||
use ../tools/runonce.nu
|
||||
|
||||
runonce run 'nu_plugin_dns' {
|
||||
^cargo install nu_plugin_dns
|
||||
register ~/.cargo/bin/nu_plugin_dns
|
||||
}
|
8
plugins/highlights.nu
Normal file
8
plugins/highlights.nu
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
|
||||
# https://github.com/FMotalleb/nu_plugin_port_list
|
||||
|
||||
run_once 'nu_plugin_highlight' {
|
||||
cargo install nu_plugin_highlight
|
||||
register ~/.cargo/bin/nu_plugin_highlight
|
||||
}
|
11
plugins/net.nu
Normal file
11
plugins/net.nu
Normal file
@@ -0,0 +1,11 @@
|
||||
|
||||
use ../tools/runonce.nu
|
||||
|
||||
runonce run 'nu_plugin_net' {
|
||||
cargo install nu_plugin_net
|
||||
register ~/.cargo/bin/nu_plugin_net
|
||||
}
|
||||
|
||||
|
||||
|
||||
# https://docs.rs/crate/nu_plugin_net/1.3.0
|
32
plugins/plugin_desktop_notification.nu
Normal file
32
plugins/plugin_desktop_notification.nu
Normal file
@@ -0,0 +1,32 @@
|
||||
# https://github.com/FMotalleb/nu_plugin_desktop_notifications
|
||||
|
||||
cargo install nu_plugin_desktop_notifications
|
||||
register ~/.cargo/bin/nu_plugin_desktop_notifications
|
||||
notify -t "test notification body" --summary "test title"
|
||||
|
||||
|
||||
# OTHER IMPLEMENTATION
|
||||
|
||||
def "notify_on_done" [
|
||||
task: closure
|
||||
] {
|
||||
let start = date now
|
||||
let result = do $task
|
||||
let end = date now
|
||||
let total = $end - $start | format duration sec
|
||||
let body = $"given task finished in ($total)"
|
||||
notify "task is done" $body
|
||||
return $result
|
||||
}
|
||||
|
||||
|
||||
def notify [title message] {
|
||||
# ^osascript -e 'display notification "' + $message + '" with title "' + $title + '"'
|
||||
let msg = 'display notification "' + $message + '" with title "' + $title + '"'
|
||||
$msg
|
||||
^osascript -e $msg
|
||||
}
|
||||
|
||||
notify_on_done { port scan 8.8.8.8 53 }
|
||||
|
||||
|
2
plugins/plugin_dialog.nu
Normal file
2
plugins/plugin_dialog.nu
Normal file
@@ -0,0 +1,2 @@
|
||||
|
||||
# https://github.com/Trivernis/nu-plugin-dialog
|
10
plugins/port_list.nu
Normal file
10
plugins/port_list.nu
Normal file
@@ -0,0 +1,10 @@
|
||||
|
||||
|
||||
# https://github.com/FMotalleb/nu_plugin_port_list
|
||||
|
||||
run_once 'nu_plugin_port_list' {
|
||||
cargo install nu_plugin_port_list
|
||||
register ~/.cargo/bin/nu_plugin_port_list
|
||||
}
|
||||
|
||||
port list -4 -t | where state == LISTEN | select [pid,local_port ] | sort-by local_port
|
8
plugins/port_scan.nu
Normal file
8
plugins/port_scan.nu
Normal file
@@ -0,0 +1,8 @@
|
||||
# https://github.com/FMotalleb/nu_plugin_port_scan
|
||||
|
||||
|
||||
|
||||
cargo install nu_plugin_port_scan
|
||||
register ~/.cargo/bin/nu_plugin_port_scan
|
||||
|
||||
50..60 | par-each { |it| port scan 8.8.8.8 $it -t 100ms } | where is_open | collect { $in }
|
11
plugins/web_query.nu
Normal file
11
plugins/web_query.nu
Normal file
@@ -0,0 +1,11 @@
|
||||
|
||||
use ../tools/runonce.nu
|
||||
|
||||
runonce run 'nu_plugin_query' {
|
||||
cargo install nu_plugin_query
|
||||
register ~/.cargo/bin/nu_plugin_query
|
||||
}
|
||||
|
||||
|
||||
|
||||
# https://www.nushell.sh/commands/docs/query_web.html
|
Reference in New Issue
Block a user