nu_scripts/modules/network
Antoine Sébert 7b2856ddff
fix: replace -c ['name' 'connection'] by --column { name: connection } (#646)
The documentation states that the flag `-c`/`--column` now takes a
record as argument instead of an array:
https://www.nushell.sh/commands/docs/rename.html#flags.

I have made the change, and you can check in a nu prompt that it works
as intended:
```nu
let input = (^lsof +c 0xFFFF -i -n -P)
let header = ($input | lines
	| take 1
	| each { str downcase | str replace ' name$' ' name state' })
let body = ($input | lines
	| skip 1
	| each { str replace '([^)])$' '$1 (NONE)' | str replace ' \((.+)\)$' ' $1' })
[$header] | append $body
	| to text
	| detect columns
	| upsert 'pid' { |r| $r.pid | into int }
	| rename --column { name: connection }
```
2023-10-19 15:28:19 -05:00
..
remoting refactor: (#418) 2023-04-25 17:56:25 -05:00
sockets fix: replace -c ['name' 'connection'] by --column { name: connection } (#646) 2023-10-19 15:28:19 -05:00
ssh.nu ssh complete cache use whitelist (ignore known_hosts and keys) (#553) 2023-07-15 06:57:23 -05:00