Add completions
parent
f08a539e51
commit
99b92ab304
@ -1,8 +1,5 @@
|
|||||||
# https://github.com/nushell/nu_scripts/blob/main/custom-completions/bat/bat-completions.nu
|
|
||||||
# replace bat with main
|
|
||||||
|
|
||||||
# A cat(1) clone with syntax highlighting and Git integration
|
# A cat(1) clone with syntax highlighting and Git integration
|
||||||
export extern main [
|
export extern "bat" [
|
||||||
...file: path # file to print / concatenate
|
...file: path # file to print / concatenate
|
||||||
--help # Print help (see a summary with '-h')
|
--help # Print help (see a summary with '-h')
|
||||||
-h # Print help (see more with '--help')
|
-h # Print help (see more with '--help')
|
@ -0,0 +1,460 @@
|
|||||||
|
# (HTTP) Connect through an abstract Unix domain socket
|
||||||
|
extern "curl" [
|
||||||
|
--abstract-unix-socket # (HTTP) Connect through an abstract Unix domain socket
|
||||||
|
--anyauth # (HTTP) Use most secure authentication method automatically
|
||||||
|
--append(-a) # (FTP SFTP) Upload: append to the target file
|
||||||
|
--basic # (HTTP) Use HTTP Basic authentication
|
||||||
|
--cacert # (TLS) Use the specified certificate file
|
||||||
|
--capath # (TLS) Use the specified certificate directory
|
||||||
|
--cert-status # (TLS) Use Certificate Status Request (aka OCSP stapling)
|
||||||
|
--cert-type # (TLS) Set type of the provided client certificate
|
||||||
|
--cert(-E) # (TLS) Use this cert
|
||||||
|
--ciphers # (TLS) Specifies which ciphers to use
|
||||||
|
--compressed-ssh # (SCP SFTP) Enables built-in SSH compression
|
||||||
|
--compressed # (HTTP) Request a compressed response
|
||||||
|
--config(-K) # Specify a text file to read curl arguments from
|
||||||
|
--connect-timeout # Maximum time in seconds you allow connection to take
|
||||||
|
--connect-to # For a request to the given HOST1:PORT1 pair, connect to HOST2:PORT2 instead
|
||||||
|
--continue-at(-C) # Continue/Resume a previous file transfer at the given offset
|
||||||
|
--cookie-jar(-c) # (HTTP) Write all cookies to this file
|
||||||
|
--cookie(-b) # (HTTP) Pass the data to the HTTP server in the Cookie header
|
||||||
|
--create-dirs # Create dirs for -o/--output
|
||||||
|
--crlf # (FTP SMTP) Convert LF to CRLF in upload. Useful for MVS (OS/390)
|
||||||
|
--crlfile # (TLS) Provide a file using PEM format with a Certificate Revocation List
|
||||||
|
--data-ascii # (HTTP) Alias for -d, --data
|
||||||
|
--data-binary # (HTTP) Post data exactly as specified with no processing
|
||||||
|
--data-raw # (HTTP) Post data like --data but without interpreting "@
|
||||||
|
--data-urlencode # (HTTP) Post data URL-encoded
|
||||||
|
--data(-d) # (HTTP) Sends the specified data in a POST request to the HTTP server
|
||||||
|
--delegation # (GSS/kerberos) Tell the server how much it can delegate for user creds
|
||||||
|
--digest # (HTTP) Enables HTTP Digest authentication
|
||||||
|
--disable-eprt # (FTP) Dont use EPRT and LPRT commands in active FTP
|
||||||
|
--disable-epsv # (FTP) Dont use EPSV in passive FTP
|
||||||
|
--disable(-q) # Disable curlrc
|
||||||
|
--disallow-username-in-url # (HTTP) Exit if passed a url containing a username
|
||||||
|
--dns-interface # (DNS) Send outgoing DNS requests through <interface>
|
||||||
|
--dns-ipv4-addr # (DNS) Bind to <ip-address> when making IPv4 DNS requests
|
||||||
|
--dns-ipv6-addr # (DNS) Bind to <ip-address> when making IPv6 DNS requests
|
||||||
|
--dns-servers # Set the list of DNS servers to use
|
||||||
|
--doh-url # (all) Specify which DNS-over-HTTPS (DOH) server to use to resolve hostnames
|
||||||
|
--dump-header(-D) # (HTTP FTP) Write the received protocol headers to the specified file
|
||||||
|
--egd-file # (TLS) Specify the path name to the Entropy Gathering Daemon socket
|
||||||
|
--engine # (TLS) Select the OpenSSL crypto engine to use for cipher operations
|
||||||
|
--expect100-timeout # (HTTP) Maximum time in seconds to wait for a 100-continue
|
||||||
|
--fail-early # Fail and exit on the first detected transfer error
|
||||||
|
--fail(-f) # (HTTP) Fail silently (no output at all) on server errors
|
||||||
|
--false-start # (TLS) Use false start during the TLS handshake
|
||||||
|
--form-string # (HTTP SMTP IMAP) Like --form except using value string literally
|
||||||
|
--form(-F) # (HTTP SMTP IMAP) Emulate pressing submit on filled-in form
|
||||||
|
--ftp-account # (FTP) Data for the ACCT command
|
||||||
|
--ftp-alternative-to-user # (FTP) If USER and PASS commands fail, send this command
|
||||||
|
--ftp-create-dirs # (FTP SFTP) Create missing dirs with ftp
|
||||||
|
--ftp-method # (FTP) Control what method curl should use to reach a file on an FTP(S) server
|
||||||
|
--ftp-pasv # (FTP) Use passive mode for the data connection
|
||||||
|
--ftp-port(-P) # (FTP) Reverses the default initiator/listener roles when connecting with FTP
|
||||||
|
--ftp-pret # (FTP) Tell curl to send a PRET command before PASV (and EPSV)
|
||||||
|
--ftp-skip-pasv-ip # (FTP) Use same IP instead of IP the server suggests in response to PASV
|
||||||
|
--ftp-ssl-ccc-mode # (FTP) Sets the CCC mode
|
||||||
|
--ftp-ssl-ccc # (FTP) Use CCC (Clear Command Channel) Shuts down the SSL/TLS layer after auth
|
||||||
|
--ftp-ssl-control # (FTP) Require SSL/TLS for the FTP login, clear for transfer
|
||||||
|
--get(-G) # Use GET instead of POST
|
||||||
|
--globoff(-g) # This option switches off the "URL globbing parser
|
||||||
|
--happy-eyeballs-timeout-ms # Attempt to connect to both IPv4 and IPv6 in parallel
|
||||||
|
--haproxy-protocol # (HTTP) Use HAProxy PROXY protocol
|
||||||
|
--head(-I) # (HTTP FTP FILE) Fetch the headers only
|
||||||
|
--header(-H) # (HTTP) Extra header to include in the request when sending HTTP to a server
|
||||||
|
--help(-h) # Usage help
|
||||||
|
--hostpubmd5 # (SFTP SCP) Pass a string containing 32 hexadecimal digits
|
||||||
|
# these commands break the nu's parser
|
||||||
|
#--http0.9 # (HTTP) Accept HTTP version 0.9 response
|
||||||
|
#--http1.0(-0) # (HTTP) Use HTTP version 1
|
||||||
|
#--http1.1 # (HTTP) Use HTTP version 1.1
|
||||||
|
--http2-prior-knowledge # (HTTP) Use HTTP/2 immediately (without trying HTTP1)
|
||||||
|
--http2 # (HTTP) Use HTTP version 2
|
||||||
|
--ignore-content-length # (FTP HTTP) Ignore the Content-Length header
|
||||||
|
--include(-i) # Include the HTTP response headers in the output
|
||||||
|
--insecure(-k) # (TLS) Allow insecure connections
|
||||||
|
--interface # Perform an operation using a specified interface
|
||||||
|
--ipv4(-4) # Use IPv4 only
|
||||||
|
--ipv6(-6) # Use IPv6 only
|
||||||
|
--junk-session-cookies(-j) # (HTTP) Discard all session cookies
|
||||||
|
--keepalive-time # Specify idle time before keepalive is sent
|
||||||
|
--key-type # (TLS) Private key file type
|
||||||
|
--key # (TLS SSH) Private key file name
|
||||||
|
--krb # (FTP) Enable Kerberos authentication and use
|
||||||
|
--libcurl # Write C-code equivalent to the invocation to the given file
|
||||||
|
--limit-rate # Limit bandwidth (Examples: 200K, 3m and 1G)
|
||||||
|
--list-only(-l) # (FTP POP3) (FTP) Use name-only view when listing
|
||||||
|
--local-port # Set a preferred single number or range (FROM-TO) of local ports to use
|
||||||
|
--location-trusted # (HTTP) Like -L, --location, but allow sending the name + password
|
||||||
|
--location(-L) # (HTTP) Follow redirects
|
||||||
|
--login-options # (IMAP POP3 SMTP) Specify the login options
|
||||||
|
--mail-auth # (SMTP) Specify a single address
|
||||||
|
--mail-from # (SMTP) Specify a single address that the given mail should get sent from
|
||||||
|
--mail-rcpt # (SMTP) Specify a single address, user name or mailing list name
|
||||||
|
--manual(-M) # Manual. Display the huge help text
|
||||||
|
--max-filesize # Specify the maximum size (in bytes) of a file to download
|
||||||
|
--max-redirs # (HTTP) Set maximum number of redirection-followings allowed
|
||||||
|
--max-time(-m) # Maximum time in seconds that you allow the whole operation to take
|
||||||
|
--metalink # Process URI as Metalink file
|
||||||
|
--negotiate # (HTTP) Enables Negotiate (SPNEGO) authentication
|
||||||
|
--netrc-file # Use this netrc file
|
||||||
|
--netrc-optional # Make netrc optional
|
||||||
|
--netrc(-n) # Use ~/.netrc
|
||||||
|
--next # Use a separate operation for the following URL
|
||||||
|
--no-alpn # (HTTPS) Disable the ALPN TLS extension
|
||||||
|
--no-buffer(-N) # Disable the buffering of the output stream
|
||||||
|
--no-keepalive # Disable use of keepalive messages on the TCP connection
|
||||||
|
--no-npn # (HTTPS) Disable NPN TLS extension
|
||||||
|
--no-sessionid # (TLS) Disable use of SSL session-ID caching
|
||||||
|
--noproxy # Comma-separated list of hosts which do not use a proxy
|
||||||
|
--ntlm-wb # (HTTP) Enable NTLM, but hand over auth to separate ntlmauth binary
|
||||||
|
--ntlm # (HTTP) Enable NTLM authentication
|
||||||
|
--oauth2-bearer # (IMAP POP3 SMTP) Specify the Bearer Token for OAUTH 2
|
||||||
|
--output(-o) # Write output to <file> instead of stdout
|
||||||
|
--pass # (SSH TLS) Passphrase for the private key
|
||||||
|
--path-as-is # Do not handle sequences of /../ or /./ in the given URL path
|
||||||
|
--pinnedpubkey # (TLS) Use the specified public key file (or hashes)
|
||||||
|
--post301 # (HTTP) Respect RFC 7231/6.4
|
||||||
|
--post302 # (HTTP) Respect RFC 7231/6.4
|
||||||
|
--post303 # (HTTP) Violate RFC 7231/6.4
|
||||||
|
--preproxy # Use the specified SOCKS proxy before connecting to HTTP(S) proxy
|
||||||
|
--progress-bar # Display progress as a simple progress bar
|
||||||
|
# --progress-bar(-#) # (this short flag breaks nu parser) Display progress as a simple progress bar
|
||||||
|
--proto-default # Use this protocol for any URL missing a scheme name
|
||||||
|
--proto-redir # Limit what protocols it may use on redirect
|
||||||
|
--proto # Limit what protocols it may use in the transfer
|
||||||
|
--proxy-anyauth # Like --anyauth but for the proxy
|
||||||
|
--proxy-basic # Use HTTP Basic authentication to communicate with proxy
|
||||||
|
--proxy-cacert # Same as --cacert but used in HTTPS proxy context
|
||||||
|
--proxy-capath # Same as --capath but used in HTTPS proxy context
|
||||||
|
--proxy-cert-type # Same as --cert-type but used in HTTPS proxy context
|
||||||
|
--proxy-cert # Same as -E, --cert but used in HTTPS proxy context
|
||||||
|
--proxy-ciphers # Same as --ciphers but used in HTTPS proxy context
|
||||||
|
--proxy-crlfile # Same as --crlfile but used in HTTPS proxy context
|
||||||
|
--proxy-digest # Use HTTP Digest authentication to communicate with proxy
|
||||||
|
--proxy-header # (HTTP) Extra header to include in the request when sending HTTP to a proxy
|
||||||
|
--proxy-insecure # Same as -k, --insecure but used in HTTPS proxy context
|
||||||
|
--proxy-key-type # Same as --key-type but used in HTTPS proxy context
|
||||||
|
--proxy-key # Same as --key but used in HTTPS proxy context
|
||||||
|
--proxy-negotiate # Use HTTP Negotiate authentication to communicate with proxy
|
||||||
|
--proxy-ntlm # Use HTTP NTLM authentication when to communicate with proxy
|
||||||
|
--proxy-pass # Same as --pass but used in HTTPS proxy context
|
||||||
|
--proxy-pinnedpubkey # (TLS) Use specified public key file or hashes to verify proxy
|
||||||
|
--proxy-service-name # This option allows you to change the service name for proxy negotiation
|
||||||
|
--proxy-ssl-allow-beast # Same as --ssl-allow-beast but used in HTTPS proxy context
|
||||||
|
--proxy-tls13-ciphers # (TLS) Specify cipher suites for TLS 1.3 proxy connection
|
||||||
|
--proxy-tlsauthtype # Same as --tlsauthtype but used in HTTPS proxy context
|
||||||
|
--proxy-tlspassword # Same as --tlspassword but used in HTTPS proxy context
|
||||||
|
--proxy-tlsuser # Same as --tlsuser but used in HTTPS proxy context
|
||||||
|
--proxy-tlsv1 # Same as -1, --tlsv1 but used in HTTPS proxy context
|
||||||
|
--proxy-user(-U) # Specify the user name and password to use for proxy authentication
|
||||||
|
--proxy(-x) # Use the specified proxy
|
||||||
|
# --proxy1.0 # This breaks nu parser. Use the specified HTTP 1.0 proxy
|
||||||
|
--proxytunnel(-p) # If HTTP proxy is used, make curl tunnel through it
|
||||||
|
--pubkey # (SFTP SCP) Public key file name
|
||||||
|
--quote(-Q) # (FTP SFTP) Send an arbitrary command to the remote FTP or SFTP server
|
||||||
|
--random-file # Specify file containing random data
|
||||||
|
--range(-r) # (HTTP FTP SFTP FILE) Retrieve a byte range
|
||||||
|
--raw # (HTTP) Pass raw data (no HTTP decoding or transfer encoding)
|
||||||
|
--referer(-e) # (HTTP) Sends the "Referrer Page" information to the HTTP server
|
||||||
|
--remote-header-name(-J) # (HTTP) Save output to filename from Content-Disposition
|
||||||
|
--remote-name-all # For every URL write output to local file by default
|
||||||
|
--remote-name(-O) # Write output to a local file named like the remote file we get
|
||||||
|
--remote-time(-R) # Use timestamp of remote file on output
|
||||||
|
--request-target # (HTTP) Use an alternative request target
|
||||||
|
--request(-X) # (HTTP) Specifies a custom HTTP method
|
||||||
|
--resolve # Provide a custom address for a specific host and port pair
|
||||||
|
--retry-connrefused # Consider ECONNREFUSED a transient error
|
||||||
|
--retry-delay # Time to wait between transfer retries
|
||||||
|
--retry-max-time # The retry timer is reset before the first transfer attempt
|
||||||
|
--retry # Number of retries when transient error occurs
|
||||||
|
--sasl-ir # Enable initial response in SASL authentication
|
||||||
|
--service-name # This option allows you to change the service name for SPNEGO
|
||||||
|
--show-error(-S) # When used with -s, --silent, it makes curl show an error message if it fails
|
||||||
|
--silent(-s) # Silent or quiet mode. Dont show progress meter or error messages
|
||||||
|
--socks4 # Use the specified SOCKS4 proxy
|
||||||
|
--socks4a # Use the specified SOCKS4a proxy
|
||||||
|
--socks5-basic # Use username/password authentication to connect to SOCKS5 proxy
|
||||||
|
--socks5-gssapi-nec # As part of the GSS-API negotiation a protection mode is negotiated
|
||||||
|
--socks5-gssapi-service # The default service name for a socks server is rcmd/server-fqdn
|
||||||
|
--socks5-gssapi # Tells curl to use GSS-API authentication when connecting to a SOCKS5 proxy
|
||||||
|
--socks5-hostname # Use the specified SOCKS5 proxy (and let the proxy resolve the host name)
|
||||||
|
--socks5 # Use the specified SOCKS5 proxy - but resolve the host name locally
|
||||||
|
--speed-limit(-Y) # Abort download if its slower than given speed (Bps) for speed-time
|
||||||
|
--speed-time(-y) # Abort download if its slower than speed for given speed-time (s)
|
||||||
|
--ssl-allow-beast # Dont work around BEAST security flaw in SSL3 and TLS1.0
|
||||||
|
--ssl-no-revoke # (Schannel) This option tells curl to disable certificate revocation checks
|
||||||
|
--ssl-reqd # (FTP IMAP POP3 SMTP) Require SSL/TLS for the connection
|
||||||
|
--ssl # (FTP IMAP POP3 SMTP) Try to use SSL/TLS for the connection
|
||||||
|
--sslv2(-2) # (SSL) Use SSL version 2
|
||||||
|
--sslv3(-3) # (SSL) Use SSL version 3
|
||||||
|
--stderr # Redirect all writes to stderr to the specified file instead
|
||||||
|
--styled-output # Use bold font styles when writing HTTP headers to terminal
|
||||||
|
--suppress-connect-headers # Dont print response headers for CONNECT request if -p is set
|
||||||
|
--tcp-fastopen # Enable use of TCP Fast Open
|
||||||
|
--tcp-nodelay # Turn on the TCP_NODELAY option
|
||||||
|
--telnet-option(-t) # Pass options to the telnet protocol
|
||||||
|
--tftp-blksize # (TFTP) Set TFTP BLKSIZE option (must be >512)
|
||||||
|
--tftp-no-options # (TFTP) Tells curl not to send TFTP options requests
|
||||||
|
--time-cond(-z) # (HTTP FTP) Request file modified before or later than given time
|
||||||
|
--tls-max # (SSL) VERSION defines maximum supported TLS version
|
||||||
|
--tls13-ciphers # (TLS) Specifies cipher suites to use for TLS 1.3
|
||||||
|
--tlsauthtype # Set TLS authentication type
|
||||||
|
--tlspassword # Set password for use with the TLS authentication method
|
||||||
|
--tlsuser # Set username for use with the TLS authentication method
|
||||||
|
# these commands break the nu's parser
|
||||||
|
#--tlsv1.0 # (TLS) Forces curl to use TLS version 1.0
|
||||||
|
#--tlsv1.1 # (TLS) Forces curl to use TLS version 1.1
|
||||||
|
#--tlsv1.2 # (TLS) Forces curl to use TLS version 1.2
|
||||||
|
#--tlsv1.3 # (TLS) Forces curl to use TLS version 1.3
|
||||||
|
--tlsv1 # (SSL) Tells curl to use at least TLS version 1
|
||||||
|
--tr-encoding # (HTTP) Request compressed Transfer-Encoding, uncompress on receive
|
||||||
|
--trace-ascii # Enables a full trace dump of all incoming and outgoing data
|
||||||
|
--trace-time # Prepends a time stamp to each trace or verbose line that curl displays
|
||||||
|
--trace # Enables a full trace dump of all incoming and outgoing data
|
||||||
|
--unix-socket # (HTTP) Connect through this Unix domain socket, instead of using the network
|
||||||
|
--upload-file(-T) # This transfers the specified local file to the remote URL
|
||||||
|
--url # Specify a URL to fetch
|
||||||
|
--use-ascii(-B) # (FTP LDAP) Enable ASCII transfer
|
||||||
|
--user-agent(-A) # (HTTP) Specify the User-Agent string to send to the HTTP server
|
||||||
|
--user(-u) # Specify the user name and password to use for server authentication
|
||||||
|
--verbose(-v) # Makes curl verbose during the operation
|
||||||
|
--version(-V) # Displays information about curl and the libcurl version it uses
|
||||||
|
--write-out(-w) # Make curl display information on stdout after a completed transfer
|
||||||
|
--no-eprt # for --disable-eprt
|
||||||
|
--no-epsv # for --disable-epsv
|
||||||
|
--max-redir # Set maximum number of redirects
|
||||||
|
--xattr # Store metadata in xattrs (like origin URL)
|
||||||
|
...args
|
||||||
|
]
|
||||||
|
|
||||||
|
# (TLS) Set type of the provided client certificate
|
||||||
|
extern "curl PEM, DER ENG P12" [
|
||||||
|
--abstract-unix-socket # (HTTP) Connect through an abstract Unix domain socket
|
||||||
|
--anyauth # (HTTP) Use most secure authentication method automatically
|
||||||
|
--append(-a) # (FTP SFTP) Upload: append to the target file
|
||||||
|
--basic # (HTTP) Use HTTP Basic authentication
|
||||||
|
--cacert # (TLS) Use the specified certificate file
|
||||||
|
--capath # (TLS) Use the specified certificate directory
|
||||||
|
--cert-status # (TLS) Use Certificate Status Request (aka OCSP stapling)
|
||||||
|
--cert-type # (TLS) Set type of the provided client certificate
|
||||||
|
--cert(-E) # (TLS) Use this cert
|
||||||
|
--ciphers # (TLS) Specifies which ciphers to use
|
||||||
|
--compressed-ssh # (SCP SFTP) Enables built-in SSH compression
|
||||||
|
--compressed # (HTTP) Request a compressed response
|
||||||
|
--config(-K) # Specify a text file to read curl arguments from
|
||||||
|
--connect-timeout # Maximum time in seconds you allow connection to take
|
||||||
|
--connect-to # For a request to the given HOST1:PORT1 pair, connect to HOST2:PORT2 instead
|
||||||
|
--continue-at(-C) # Continue/Resume a previous file transfer at the given offset
|
||||||
|
--cookie-jar(-c) # (HTTP) Write all cookies to this file
|
||||||
|
--cookie(-b) # (HTTP) Pass the data to the HTTP server in the Cookie header
|
||||||
|
--create-dirs # Create dirs for -o/--output
|
||||||
|
--crlf # (FTP SMTP) Convert LF to CRLF in upload. Useful for MVS (OS/390)
|
||||||
|
--crlfile # (TLS) Provide a file using PEM format with a Certificate Revocation List
|
||||||
|
--data-ascii # (HTTP) Alias for -d, --data
|
||||||
|
--data-binary # (HTTP) Post data exactly as specified with no processing
|
||||||
|
--data-raw # (HTTP) Post data like --data but without interpreting "@
|
||||||
|
--data-urlencode # (HTTP) Post data URL-encoded
|
||||||
|
--data(-d) # (HTTP) Sends the specified data in a POST request to the HTTP server
|
||||||
|
--delegation # (GSS/kerberos) Tell the server how much it can delegate for user creds
|
||||||
|
--digest # (HTTP) Enables HTTP Digest authentication
|
||||||
|
--disable-eprt # (FTP) Dont use EPRT and LPRT commands in active FTP
|
||||||
|
--disable-epsv # (FTP) Dont use EPSV in passive FTP
|
||||||
|
--disable(-q) # Disable curlrc
|
||||||
|
--disallow-username-in-url # (HTTP) Exit if passed a url containing a username
|
||||||
|
--dns-interface # (DNS) Send outgoing DNS requests through <interface>
|
||||||
|
--dns-ipv4-addr # (DNS) Bind to <ip-address> when making IPv4 DNS requests
|
||||||
|
--dns-ipv6-addr # (DNS) Bind to <ip-address> when making IPv6 DNS requests
|
||||||
|
--dns-servers # Set the list of DNS servers to use
|
||||||
|
--doh-url # (all) Specify which DNS-over-HTTPS (DOH) server to use to resolve hostnames
|
||||||
|
--dump-header(-D) # (HTTP FTP) Write the received protocol headers to the specified file
|
||||||
|
--egd-file # (TLS) Specify the path name to the Entropy Gathering Daemon socket
|
||||||
|
--engine # (TLS) Select the OpenSSL crypto engine to use for cipher operations
|
||||||
|
--expect100-timeout # (HTTP) Maximum time in seconds to wait for a 100-continue
|
||||||
|
--fail-early # Fail and exit on the first detected transfer error
|
||||||
|
--fail(-f) # (HTTP) Fail silently (no output at all) on server errors
|
||||||
|
--false-start # (TLS) Use false start during the TLS handshake
|
||||||
|
--form-string # (HTTP SMTP IMAP) Like --form except using value string literally
|
||||||
|
--form(-F) # (HTTP SMTP IMAP) Emulate pressing submit on filled-in form
|
||||||
|
--ftp-account # (FTP) Data for the ACCT command
|
||||||
|
--ftp-alternative-to-user # (FTP) If USER and PASS commands fail, send this command
|
||||||
|
--ftp-create-dirs # (FTP SFTP) Create missing dirs with ftp
|
||||||
|
--ftp-method # (FTP) Control what method curl should use to reach a file on an FTP(S) server
|
||||||
|
--ftp-pasv # (FTP) Use passive mode for the data connection
|
||||||
|
--ftp-port(-P) # (FTP) Reverses the default initiator/listener roles when connecting with FTP
|
||||||
|
--ftp-pret # (FTP) Tell curl to send a PRET command before PASV (and EPSV)
|
||||||
|
--ftp-skip-pasv-ip # (FTP) Use same IP instead of IP the server suggests in response to PASV
|
||||||
|
--ftp-ssl-ccc-mode # (FTP) Sets the CCC mode
|
||||||
|
--ftp-ssl-ccc # (FTP) Use CCC (Clear Command Channel) Shuts down the SSL/TLS layer after auth
|
||||||
|
--ftp-ssl-control # (FTP) Require SSL/TLS for the FTP login, clear for transfer
|
||||||
|
--get(-G) # Use GET instead of POST
|
||||||
|
--globoff(-g) # This option switches off the "URL globbing parser
|
||||||
|
--happy-eyeballs-timeout-ms # Attempt to connect to both IPv4 and IPv6 in parallel
|
||||||
|
--haproxy-protocol # (HTTP) Use HAProxy PROXY protocol
|
||||||
|
--head(-I) # (HTTP FTP FILE) Fetch the headers only
|
||||||
|
--header(-H) # (HTTP) Extra header to include in the request when sending HTTP to a server
|
||||||
|
--help(-h) # Usage help
|
||||||
|
--hostpubmd5 # (SFTP SCP) Pass a string containing 32 hexadecimal digits
|
||||||
|
# these commands break the nu's parser
|
||||||
|
#--http0.9 # (HTTP) Accept HTTP version 0.9 response
|
||||||
|
#--http1.0(-0) # (HTTP) Use HTTP version 1
|
||||||
|
#--http1.1 # (HTTP) Use HTTP version 1.1
|
||||||
|
--http2-prior-knowledge # (HTTP) Use HTTP/2 immediately (without trying HTTP1)
|
||||||
|
--http2 # (HTTP) Use HTTP version 2
|
||||||
|
--ignore-content-length # (FTP HTTP) Ignore the Content-Length header
|
||||||
|
--include(-i) # Include the HTTP response headers in the output
|
||||||
|
--insecure(-k) # (TLS) Allow insecure connections
|
||||||
|
--interface # Perform an operation using a specified interface
|
||||||
|
--ipv4(-4) # Use IPv4 only
|
||||||
|
--ipv6(-6) # Use IPv6 only
|
||||||
|
--junk-session-cookies(-j) # (HTTP) Discard all session cookies
|
||||||
|
--keepalive-time # Specify idle time before keepalive is sent
|
||||||
|
--key-type # (TLS) Private key file type
|
||||||
|
--key # (TLS SSH) Private key file name
|
||||||
|
--krb # (FTP) Enable Kerberos authentication and use
|
||||||
|
--libcurl # Write C-code equivalent to the invocation to the given file
|
||||||
|
--limit-rate # Limit bandwidth (Examples: 200K, 3m and 1G)
|
||||||
|
--list-only(-l) # (FTP POP3) (FTP) Use name-only view when listing
|
||||||
|
--local-port # Set a preferred single number or range (FROM-TO) of local ports to use
|
||||||
|
--location-trusted # (HTTP) Like -L, --location, but allow sending the name + password
|
||||||
|
--location(-L) # (HTTP) Follow redirects
|
||||||
|
--login-options # (IMAP POP3 SMTP) Specify the login options
|
||||||
|
--mail-auth # (SMTP) Specify a single address
|
||||||
|
--mail-from # (SMTP) Specify a single address that the given mail should get sent from
|
||||||
|
--mail-rcpt # (SMTP) Specify a single address, user name or mailing list name
|
||||||
|
--manual(-M) # Manual. Display the huge help text
|
||||||
|
--max-filesize # Specify the maximum size (in bytes) of a file to download
|
||||||
|
--max-redirs # (HTTP) Set maximum number of redirection-followings allowed
|
||||||
|
--max-time(-m) # Maximum time in seconds that you allow the whole operation to take
|
||||||
|
--metalink # Process URI as Metalink file
|
||||||
|
--negotiate # (HTTP) Enables Negotiate (SPNEGO) authentication
|
||||||
|
--netrc-file # Use this netrc file
|
||||||
|
--netrc-optional # Make netrc optional
|
||||||
|
--netrc(-n) # Use ~/.netrc
|
||||||
|
--next # Use a separate operation for the following URL
|
||||||
|
--no-alpn # (HTTPS) Disable the ALPN TLS extension
|
||||||
|
--no-buffer(-N) # Disable the buffering of the output stream
|
||||||
|
--no-keepalive # Disable use of keepalive messages on the TCP connection
|
||||||
|
--no-npn # (HTTPS) Disable NPN TLS extension
|
||||||
|
--no-sessionid # (TLS) Disable use of SSL session-ID caching
|
||||||
|
--noproxy # Comma-separated list of hosts which do not use a proxy
|
||||||
|
--ntlm-wb # (HTTP) Enable NTLM, but hand over auth to separate ntlmauth binary
|
||||||
|
--ntlm # (HTTP) Enable NTLM authentication
|
||||||
|
--oauth2-bearer # (IMAP POP3 SMTP) Specify the Bearer Token for OAUTH 2
|
||||||
|
--output(-o) # Write output to <file> instead of stdout
|
||||||
|
--pass # (SSH TLS) Passphrase for the private key
|
||||||
|
--path-as-is # Do not handle sequences of /../ or /./ in the given URL path
|
||||||
|
--pinnedpubkey # (TLS) Use the specified public key file (or hashes)
|
||||||
|
--post301 # (HTTP) Respect RFC 7231/6.4
|
||||||
|
--post302 # (HTTP) Respect RFC 7231/6.4
|
||||||
|
--post303 # (HTTP) Violate RFC 7231/6.4
|
||||||
|
--preproxy # Use the specified SOCKS proxy before connecting to HTTP(S) proxy
|
||||||
|
--progress-bar # Display progress as a simple progress bar
|
||||||
|
# --progress-bar(-#) # (this short flag breaks nu parser) Display progress as a simple progress bar
|
||||||
|
--proto-default # Use this protocol for any URL missing a scheme name
|
||||||
|
--proto-redir # Limit what protocols it may use on redirect
|
||||||
|
--proto # Limit what protocols it may use in the transfer
|
||||||
|
--proxy-anyauth # Like --anyauth but for the proxy
|
||||||
|
--proxy-basic # Use HTTP Basic authentication to communicate with proxy
|
||||||
|
--proxy-cacert # Same as --cacert but used in HTTPS proxy context
|
||||||
|
--proxy-capath # Same as --capath but used in HTTPS proxy context
|
||||||
|
--proxy-cert-type # Same as --cert-type but used in HTTPS proxy context
|
||||||
|
--proxy-cert # Same as -E, --cert but used in HTTPS proxy context
|
||||||
|
--proxy-ciphers # Same as --ciphers but used in HTTPS proxy context
|
||||||
|
--proxy-crlfile # Same as --crlfile but used in HTTPS proxy context
|
||||||
|
--proxy-digest # Use HTTP Digest authentication to communicate with proxy
|
||||||
|
--proxy-header # (HTTP) Extra header to include in the request when sending HTTP to a proxy
|
||||||
|
--proxy-insecure # Same as -k, --insecure but used in HTTPS proxy context
|
||||||
|
--proxy-key-type # Same as --key-type but used in HTTPS proxy context
|
||||||
|
--proxy-key # Same as --key but used in HTTPS proxy context
|
||||||
|
--proxy-negotiate # Use HTTP Negotiate authentication to communicate with proxy
|
||||||
|
--proxy-ntlm # Use HTTP NTLM authentication when to communicate with proxy
|
||||||
|
--proxy-pass # Same as --pass but used in HTTPS proxy context
|
||||||
|
--proxy-pinnedpubkey # (TLS) Use specified public key file or hashes to verify proxy
|
||||||
|
--proxy-service-name # This option allows you to change the service name for proxy negotiation
|
||||||
|
--proxy-ssl-allow-beast # Same as --ssl-allow-beast but used in HTTPS proxy context
|
||||||
|
--proxy-tls13-ciphers # (TLS) Specify cipher suites for TLS 1.3 proxy connection
|
||||||
|
--proxy-tlsauthtype # Same as --tlsauthtype but used in HTTPS proxy context
|
||||||
|
--proxy-tlspassword # Same as --tlspassword but used in HTTPS proxy context
|
||||||
|
--proxy-tlsuser # Same as --tlsuser but used in HTTPS proxy context
|
||||||
|
--proxy-tlsv1 # Same as -1, --tlsv1 but used in HTTPS proxy context
|
||||||
|
--proxy-user(-U) # Specify the user name and password to use for proxy authentication
|
||||||
|
--proxy(-x) # Use the specified proxy
|
||||||
|
#--proxy1.0 # Use the specified HTTP 1.0 proxy
|
||||||
|
--proxytunnel(-p) # If HTTP proxy is used, make curl tunnel through it
|
||||||
|
--pubkey # (SFTP SCP) Public key file name
|
||||||
|
--quote(-Q) # (FTP SFTP) Send an arbitrary command to the remote FTP or SFTP server
|
||||||
|
--random-file # Specify file containing random data
|
||||||
|
--range(-r) # (HTTP FTP SFTP FILE) Retrieve a byte range
|
||||||
|
--raw # (HTTP) Pass raw data (no HTTP decoding or transfer encoding)
|
||||||
|
--referer(-e) # (HTTP) Sends the "Referrer Page" information to the HTTP server
|
||||||
|
--remote-header-name(-J) # (HTTP) Save output to filename from Content-Disposition
|
||||||
|
--remote-name-all # For every URL write output to local file by default
|
||||||
|
--remote-name(-O) # Write output to a local file named like the remote file we get
|
||||||
|
--remote-time(-R) # Use timestamp of remote file on output
|
||||||
|
--request-target # (HTTP) Use an alternative request target
|
||||||
|
--request(-X) # (HTTP) Specifies a custom HTTP method
|
||||||
|
--resolve # Provide a custom address for a specific host and port pair
|
||||||
|
--retry-connrefused # Consider ECONNREFUSED a transient error
|
||||||
|
--retry-delay # Time to wait between transfer retries
|
||||||
|
--retry-max-time # The retry timer is reset before the first transfer attempt
|
||||||
|
--retry # Number of retries when transient error occurs
|
||||||
|
--sasl-ir # Enable initial response in SASL authentication
|
||||||
|
--service-name # This option allows you to change the service name for SPNEGO
|
||||||
|
--show-error(-S) # When used with -s, --silent, it makes curl show an error message if it fails
|
||||||
|
--silent(-s) # Silent or quiet mode. Dont show progress meter or error messages
|
||||||
|
--socks4 # Use the specified SOCKS4 proxy
|
||||||
|
--socks4a # Use the specified SOCKS4a proxy
|
||||||
|
--socks5-basic # Use username/password authentication to connect to SOCKS5 proxy
|
||||||
|
--socks5-gssapi-nec # As part of the GSS-API negotiation a protection mode is negotiated
|
||||||
|
--socks5-gssapi-service # The default service name for a socks server is rcmd/server-fqdn
|
||||||
|
--socks5-gssapi # Tells curl to use GSS-API authentication when connecting to a SOCKS5 proxy
|
||||||
|
--socks5-hostname # Use the specified SOCKS5 proxy (and let the proxy resolve the host name)
|
||||||
|
--socks5 # Use the specified SOCKS5 proxy - but resolve the host name locally
|
||||||
|
--speed-limit(-Y) # Abort download if its slower than given speed (Bps) for speed-time
|
||||||
|
--speed-time(-y) # Abort download if its slower than speed for given speed-time (s)
|
||||||
|
--ssl-allow-beast # Dont work around BEAST security flaw in SSL3 and TLS1.0
|
||||||
|
--ssl-no-revoke # (Schannel) This option tells curl to disable certificate revocation checks
|
||||||
|
--ssl-reqd # (FTP IMAP POP3 SMTP) Require SSL/TLS for the connection
|
||||||
|
--ssl # (FTP IMAP POP3 SMTP) Try to use SSL/TLS for the connection
|
||||||
|
--sslv2(-2) # (SSL) Use SSL version 2
|
||||||
|
--sslv3(-3) # (SSL) Use SSL version 3
|
||||||
|
--stderr # Redirect all writes to stderr to the specified file instead
|
||||||
|
--styled-output # Use bold font styles when writing HTTP headers to terminal
|
||||||
|
--suppress-connect-headers # Dont print response headers for CONNECT request if -p is set
|
||||||
|
--tcp-fastopen # Enable use of TCP Fast Open
|
||||||
|
--tcp-nodelay # Turn on the TCP_NODELAY option
|
||||||
|
--telnet-option(-t) # Pass options to the telnet protocol
|
||||||
|
--tftp-blksize # (TFTP) Set TFTP BLKSIZE option (must be >512)
|
||||||
|
--tftp-no-options # (TFTP) Tells curl not to send TFTP options requests
|
||||||
|
--time-cond(-z) # (HTTP FTP) Request file modified before or later than given time
|
||||||
|
--tls-max # (SSL) VERSION defines maximum supported TLS version
|
||||||
|
--tls13-ciphers # (TLS) Specifies cipher suites to use for TLS 1.3
|
||||||
|
--tlsauthtype # Set TLS authentication type
|
||||||
|
--tlspassword # Set password for use with the TLS authentication method
|
||||||
|
--tlsuser # Set username for use with the TLS authentication method
|
||||||
|
#--tlsv1.0 # (TLS) Forces curl to use TLS version 1.0
|
||||||
|
#--tlsv1.1 # (TLS) Forces curl to use TLS version 1.1
|
||||||
|
#--tlsv1.2 # (TLS) Forces curl to use TLS version 1.2
|
||||||
|
#--tlsv1.3 # (TLS) Forces curl to use TLS version 1.3
|
||||||
|
--tlsv1 # (SSL) Tells curl to use at least TLS version 1
|
||||||
|
--tr-encoding # (HTTP) Request compressed Transfer-Encoding, uncompress on receive
|
||||||
|
--trace-ascii # Enables a full trace dump of all incoming and outgoing data
|
||||||
|
--trace-time # Prepends a time stamp to each trace or verbose line that curl displays
|
||||||
|
--trace # Enables a full trace dump of all incoming and outgoing data
|
||||||
|
--unix-socket # (HTTP) Connect through this Unix domain socket, instead of using the network
|
||||||
|
--upload-file(-T) # This transfers the specified local file to the remote URL
|
||||||
|
--url # Specify a URL to fetch
|
||||||
|
--use-ascii(-B) # (FTP LDAP) Enable ASCII transfer
|
||||||
|
--user-agent(-A) # (HTTP) Specify the User-Agent string to send to the HTTP server
|
||||||
|
--user(-u) # Specify the user name and password to use for server authentication
|
||||||
|
--verbose(-v) # Makes curl verbose during the operation
|
||||||
|
--version(-V) # Displays information about curl and the libcurl version it uses
|
||||||
|
--write-out(-w) # Make curl display information on stdout after a completed transfer
|
||||||
|
--no-eprt # for --disable-eprt
|
||||||
|
--no-epsv # for --disable-epsv
|
||||||
|
--max-redir # Set maximum number of redirects
|
||||||
|
--xattr # Store metadata in xattrs (like origin URL)
|
||||||
|
...args
|
||||||
|
]
|
@ -0,0 +1,678 @@
|
|||||||
|
def "nu-complete docker containers" [] {
|
||||||
|
^docker ps -a --format "{{.ID}} {{.Names}}" | lines
|
||||||
|
| parse "{value} {description}"
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker images" [] {
|
||||||
|
^docker images --format "{{.ID}} {{.Repository}}" | lines
|
||||||
|
| parse "{value} {description}"
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker run" [] {
|
||||||
|
(nu-complete docker images)
|
||||||
|
| append (nu-complete docker containers)
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker pull" [] {
|
||||||
|
[always, missing, never]
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker remove image" [] {
|
||||||
|
[local, all]
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete local files" [] {
|
||||||
|
^ls | lines
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker compose ps" [] {
|
||||||
|
^docker compose ps -a --format "{{.ID}} {{.Names}}" | lines
|
||||||
|
| parse "{value} {description}"
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete docker compose service status" [] {
|
||||||
|
[paused restarting removing running dead created exited]
|
||||||
|
}
|
||||||
|
|
||||||
|
# Log in to a Docker registry
|
||||||
|
export extern "docker login" [
|
||||||
|
server?: string #Docker registry URL
|
||||||
|
--password(-p): string #Password
|
||||||
|
--password-stdin #Take the password from stdin
|
||||||
|
--username(-u): string #Username
|
||||||
|
]
|
||||||
|
|
||||||
|
# Log out from a Docker registry
|
||||||
|
export extern "docker logout" [
|
||||||
|
server?: string #Docker registry URL
|
||||||
|
]
|
||||||
|
|
||||||
|
# Search Docker Hub for images
|
||||||
|
export extern "docker search" [
|
||||||
|
term?: string
|
||||||
|
--filter(-f): string #Filter output based on conditions provided
|
||||||
|
--format: string #Pretty-print search using a Go template
|
||||||
|
--limit: int #Max number of search results
|
||||||
|
--no-trunc #Don't truncate output
|
||||||
|
]
|
||||||
|
|
||||||
|
# Show the docker version information
|
||||||
|
export extern "docker version" [
|
||||||
|
--format(-f): string #Format the output using the given Go template
|
||||||
|
--kubeconfig: string #Kubernetes config file
|
||||||
|
]
|
||||||
|
|
||||||
|
# Inspect changes to files or directories on a container's filesystem
|
||||||
|
export extern "docker system events" [
|
||||||
|
--filter(-f): string #Filter output based on conditions provided
|
||||||
|
--format: string #Pretty-print images using a Go template
|
||||||
|
--since: string #Show all events created since timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
||||||
|
--until: string #Stream events until this timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
||||||
|
]
|
||||||
|
|
||||||
|
# Attach local standard input, output, and error streams to a running container
|
||||||
|
export extern "docker container attach" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--detach-keys:string #Override the key sequence for detaching a container
|
||||||
|
--no-stdin #Do not attach STDIN
|
||||||
|
--sig-proxy #Proxy all received signals to the process
|
||||||
|
]
|
||||||
|
|
||||||
|
# Create a new image from a container's changes
|
||||||
|
export extern "docker container commit" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--author(-a): string #Author (e.g., "John Hannibal Smith <hannibal@a-team.com>"
|
||||||
|
--change(-c): string #Apply Dockerfile instruction to the created image
|
||||||
|
--message(-m): string #Commit message
|
||||||
|
--pause(-p) #Pause container during commit (default true)
|
||||||
|
]
|
||||||
|
|
||||||
|
# Create a new container
|
||||||
|
export extern "docker container create" [
|
||||||
|
image?: string@"nu-complete docker images" #The image to create the container from
|
||||||
|
command?: string #Command to run inside the container
|
||||||
|
...args: string
|
||||||
|
--add-host: string #Add a custom host-to-IP mapping (host:ip)
|
||||||
|
--annotation: string #Add an annotation to the container (passed through to the OCI runtime) (default map[])
|
||||||
|
--attach: string #Attach to STDIN, STDOUT or STDERR
|
||||||
|
--blkio-weight: int #Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
||||||
|
--blkio-weight-device: string #Block IO weight (relative device weight) (default [])
|
||||||
|
--cap-add: string #Add Linux capabilities
|
||||||
|
--cap-drop: string #Drop Linux capabilities
|
||||||
|
--cgroup-parent: string #Optional parent cgroup for the container
|
||||||
|
--cgroupns: string #Cgroup namespace to use (host|private)
|
||||||
|
--cidfile: string #Write the container ID to the file
|
||||||
|
--cpu-period: int #Limit CPU CFS (Completely Fair Scheduler) period
|
||||||
|
--cpu-quota: int #Limit CPU CFS (Completely Fair Scheduler) quota
|
||||||
|
--cpu-rt-period: int #Limit CPU real-time period in microseconds
|
||||||
|
--cpu-rt-runtime: int #Limit CPU real-time runtime in microseconds
|
||||||
|
--cpu-shares(-c): int #CPU shares (relative weight)
|
||||||
|
--cpus: int #Number of CPUs
|
||||||
|
--cpuset-cpus: string #CPUs in which to allow execution (0-3, 0,1)
|
||||||
|
--cpuset-mems: string #MEMs in which to allow execution (0-3, 0,1)
|
||||||
|
--detach(-d) #Run container in background and print container ID
|
||||||
|
--detach-keys: string #Override the key sequence for detaching a container
|
||||||
|
--device: string #Add a host device to the container
|
||||||
|
--device-cgroup-rule: string #Add a rule to the cgroup allowed devices list
|
||||||
|
--device-read-bps: int #Limit read rate (bytes per second) from a device (default [])
|
||||||
|
--device-read-iops: int #Limit read rate (IO per second) from a device (default [])
|
||||||
|
--device-write-bps: int #Limit write rate (bytes per second) to a device (default [])
|
||||||
|
--device-write-iops: int #Limit write rate (IO per second) to a device (default [])
|
||||||
|
--disable-content-trust #Skip image verification (default true)
|
||||||
|
--dns: int #Set custom DNS servers
|
||||||
|
--dns-option: string #Set DNS options
|
||||||
|
--dns-search: string #Set custom DNS search domains
|
||||||
|
--domainname: string #Container NIS domain name
|
||||||
|
--entrypoint: string #Overwrite the default ENTRYPOINT of the image
|
||||||
|
--env(-e): string #Set environment variables
|
||||||
|
--env-file: string #Read in a file of environment variables
|
||||||
|
--expose: string #Expose a port or a range of ports
|
||||||
|
--gpus: string #GPU devices to add to the container ('all' to pass all GPUs)
|
||||||
|
--group-add: string #Add additional groups to join
|
||||||
|
--health-cmd: string #Command to run to check health
|
||||||
|
--health-interval: duration #Time between running the check (ms|s|m|h) (default 0s)
|
||||||
|
--health-retries: int #Consecutive failures needed to report unhealthy
|
||||||
|
--health-start-interval: duration #Time between running the check during the start period (ms|s|m|h) (default 0s)
|
||||||
|
--health-start-period: duration #Start period for the container to initialize before starting health-retries countdown (ms|s|m|h) (default 0s)
|
||||||
|
--health-timeout: duration #Maximum time to allow one check to run (ms|s|m|h) (default 0s)
|
||||||
|
--help #Print usage
|
||||||
|
--hostname(-h): string #Container host name
|
||||||
|
--init #Run an init inside the container that forwards signals and reaps processes
|
||||||
|
--interactive(-i) #Keep STDIN open even if not attached
|
||||||
|
--ip: string #IPv4 address (e.g., 172.30.100.104)
|
||||||
|
--ip6: string #IPv6 address (e.g., 2001:db8::33)
|
||||||
|
--ipc: string #IPC mode to use
|
||||||
|
--isolation: string #Container isolation technology
|
||||||
|
--kernel-memory: int #Kernel memory limit
|
||||||
|
--label(-l): string #Set meta data on a container
|
||||||
|
--label-file: string #Read in a line delimited file of labels
|
||||||
|
--link: string #Add link to another container
|
||||||
|
--link-local-ip: string #Container IPv4/IPv6 link-local addresses
|
||||||
|
--log-driver: string #Logging driver for the container
|
||||||
|
--log-opt: string #Log driver options
|
||||||
|
--mac-address: string #Container MAC address (e.g., 92:d0:c6:0a:29:33)
|
||||||
|
--memory(-m): int #Memory limit
|
||||||
|
--memory-reservation: int #Memory soft limit
|
||||||
|
--memory-swap: int #Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
||||||
|
--memory-swappiness: int #Tune container memory swappiness (0 to 100) (default -1)
|
||||||
|
--mount: string #Attach a filesystem mount to the container
|
||||||
|
--name: string #Assign a name to the container
|
||||||
|
--network: string #Connect a container to a network
|
||||||
|
--network-alias: string #Add network-scoped alias for the container
|
||||||
|
--no-healthcheck #Disable any container-specified HEALTHCHECK
|
||||||
|
--oom-kill-disable #Disable OOM Killer
|
||||||
|
--oom-score-adj: int #Tune host's OOM preferences (-1000 to 1000)
|
||||||
|
--pid: string #PID namespace to use
|
||||||
|
--pids-limit: int #Tune container pids limit (set -1 for unlimited)
|
||||||
|
--platform: string #Set platform if server is multi-platform capable
|
||||||
|
--privileged #Give extended privileges to this container
|
||||||
|
--publish(-p): string #Publish a container's port(s) to the host
|
||||||
|
--publish-all(-P) #Publish all exposed ports to random ports
|
||||||
|
--pull: string@"nu-complete docker pull" #Pull image before running ("always", "missing", "never") (default "missing")
|
||||||
|
--quiet(-q) #Suppress the pull output
|
||||||
|
--read-only #Mount the container's root filesystem as read only
|
||||||
|
--restart: string #Restart policy to apply when a container #exits (default "no")
|
||||||
|
--rm #Automatically remove the container when it exits
|
||||||
|
--runtime: string #Runtime to use for this container
|
||||||
|
--security-opt: string #Security Options
|
||||||
|
--shm-size: int #Size of /dev/shm
|
||||||
|
--sig-proxy #Proxy received signals to the process (default true)
|
||||||
|
--stop-signal: string #Signal to stop the container
|
||||||
|
--stop-timeout: int #Timeout (in seconds) to stop a container
|
||||||
|
--storage-opt: string #Storage driver options for the container
|
||||||
|
--sysctl: string #Sysctl options (default map[])
|
||||||
|
--tmpfs: string #Mount a tmpfs directory
|
||||||
|
--tty(-t) #Allocate a pseudo-TTY
|
||||||
|
--ulimit: int #Ulimit options (default [])
|
||||||
|
--user(-u): string #Username or UID (format: <name|uid>[:<group|gid>])
|
||||||
|
--userns: string #User namespace to use
|
||||||
|
--uts: string #UTS namespace to use
|
||||||
|
--volume(-v): string #Bind mount a volume
|
||||||
|
--volume-driver: string #Optional volume driver for the container
|
||||||
|
--volumes-from: string #Mount volumes from the specified container(s)
|
||||||
|
--workdir(-w): string #Working directory inside the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Inspect changes to files or directories on a container's filesystem
|
||||||
|
export extern "docker container diff" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Run a command in a running container
|
||||||
|
export extern "docker container exec" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--detach(-d) #Detached mode: run command in the background
|
||||||
|
--env(-e): string #Set environment variables
|
||||||
|
--interactive(-i) #Keep STDIN open even if not attached
|
||||||
|
--privileged #Give extended privileges to the command
|
||||||
|
--tty(-t) #Allocate a pseudo-TTY
|
||||||
|
--user(-u): string #Username or UID (format: <name|uid>[:<group|gid>])
|
||||||
|
--workdir(-w): string #Working directory inside the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Export a container's filesystem as a tar archive
|
||||||
|
export extern "docker container export" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--output(-o): string #Write to a file, instead of STDOUT
|
||||||
|
]
|
||||||
|
|
||||||
|
# Display detailed information on one or more containers
|
||||||
|
export extern "docker container inspect" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--format(-f):string #Format the output using the given Go template
|
||||||
|
--size(-s) #Display total file sizes
|
||||||
|
--type:string #Return JSON for specified type
|
||||||
|
]
|
||||||
|
|
||||||
|
# Kill one or more running containers
|
||||||
|
export extern "docker container kill" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--signal(-s):string #Signal to send to the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Fetch the logs of a container
|
||||||
|
export extern "docker container logs" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--details #Show extra details provided to logs
|
||||||
|
--follow(-f) #Follow log output
|
||||||
|
--since: string #Show logs since timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
||||||
|
--tail(-n): string #Number of lines to show from the end of the logs
|
||||||
|
--timestamps(-t) #Show timestamps
|
||||||
|
--until: string #Show logs before a timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
||||||
|
]
|
||||||
|
|
||||||
|
# List containers
|
||||||
|
export extern "docker container ls" [
|
||||||
|
--all(-a) #Show all containers (default shows just running)
|
||||||
|
--filter: string #Filter output based on conditions provided
|
||||||
|
--format: string #Pretty-print containers using a Go template
|
||||||
|
--last(-n): int #Show n last created containers (includes all states) (default -1)
|
||||||
|
--latest(-l) #Show the latest created container (includes all states)
|
||||||
|
--no-trunc #Don't truncate output
|
||||||
|
--quiet(-q) #Only display numeric IDs
|
||||||
|
--size(-s) #Display total file sizes
|
||||||
|
]
|
||||||
|
|
||||||
|
# Pause all processes within one or more containers
|
||||||
|
export extern "docker container pause" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Remove all stopped containers
|
||||||
|
export extern "docker container prune" [
|
||||||
|
--filter: string #Provide filter values (e.g. 'until=24h')
|
||||||
|
--force(-f) #Do not prompt for confirmation
|
||||||
|
]
|
||||||
|
|
||||||
|
# List port mappings or a specific mapping for the container
|
||||||
|
export extern "docker container port" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Rename a container
|
||||||
|
export extern "docker container rename" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
name?: string
|
||||||
|
]
|
||||||
|
|
||||||
|
# Restart one or more containers
|
||||||
|
export extern "docker container restart" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--time(-t): int #Seconds to wait for stop before killing the container
|
||||||
|
--signal(-s): string #Signal to stop the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Remove one or more containers
|
||||||
|
export extern "docker container rm" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Run a command in a new container
|
||||||
|
export extern "docker container run" [
|
||||||
|
image?: string@"nu-complete docker run" #The image to create the container from
|
||||||
|
command?: string #Command to run inside the container
|
||||||
|
...args: string
|
||||||
|
--add-host: string #Add a custom host-to-IP mapping (host:ip)
|
||||||
|
--annotation: string #Add an annotation to the container (passed through to the OCI runtime) (default map[])
|
||||||
|
--attach: string #Attach to STDIN, STDOUT or STDERR
|
||||||
|
--blkio-weight: int #Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
||||||
|
--blkio-weight-device: string #Block IO weight (relative device weight) (default [])
|
||||||
|
--cap-add: string #Add Linux capabilities
|
||||||
|
--cap-drop: string #Drop Linux capabilities
|
||||||
|
--cgroup-parent: string #Optional parent cgroup for the container
|
||||||
|
--cgroupns: string #Cgroup namespace to use (host|private)
|
||||||
|
--cidfile: string #Write the container ID to the file
|
||||||
|
--cpu-period: int #Limit CPU CFS (Completely Fair Scheduler) period
|
||||||
|
--cpu-quota: int #Limit CPU CFS (Completely Fair Scheduler) quota
|
||||||
|
--cpu-rt-period: int #Limit CPU real-time period in microseconds
|
||||||
|
--cpu-rt-runtime: int #Limit CPU real-time runtime in microseconds
|
||||||
|
--cpu-shares(-c): int #CPU shares (relative weight)
|
||||||
|
--cpus: int #Number of CPUs
|
||||||
|
--cpuset-cpus: string #CPUs in which to allow execution (0-3, 0,1)
|
||||||
|
--cpuset-mems: string #MEMs in which to allow execution (0-3, 0,1)
|
||||||
|
--detach(-d) #Run container in background and print container ID
|
||||||
|
--detach-keys: string #Override the key sequence for detaching a container
|
||||||
|
--device: string #Add a host device to the container
|
||||||
|
--device-cgroup-rule: string #Add a rule to the cgroup allowed devices int
|
||||||
|
--device-read-bps: int #Limit read rate (bytes per second) from a device (default [])
|
||||||
|
--device-read-iops: int #Limit read rate (IO per second) from a device (default [])
|
||||||
|
--device-write-bps: int #Limit write rate (bytes per second) to a device (default [])
|
||||||
|
--device-write-iops: int #Limit write rate (IO per second) to a device (default [])
|
||||||
|
--disable-content-trust #Skip image verification (default true)
|
||||||
|
--dns: int #Set custom DNS servers
|
||||||
|
--dns-option: string #Set DNS options
|
||||||
|
--dns-search: string #Set custom DNS search domains
|
||||||
|
--domainname: string #Container NIS domain name
|
||||||
|
--entrypoint: string #Overwrite the default ENTRYPOINT of the image
|
||||||
|
--env(-e): string #Set environment variables
|
||||||
|
--env-file: string #Read in a file of environment variables
|
||||||
|
--expose: string #Expose a port or a range of ports
|
||||||
|
--gpus: string #GPU devices to add to the container ('all' to pass all GPUs)
|
||||||
|
--group-add: string #Add additional groups to join
|
||||||
|
--health-cmd: string #Command to run to check health
|
||||||
|
--health-interval: duration #Time between running the check (ms|s|m|h) (default 0s)
|
||||||
|
--health-retries: int #Consecutive failures needed to report unhealthy
|
||||||
|
--health-start-interval: duration #Time between running the check during the start period (ms|s|m|h) (default 0s)
|
||||||
|
--health-start-period: duration #Start period for the container to initialize before starting health-retries countdown (ms|s|m|h) (default 0s)
|
||||||
|
--health-timeout: duration #Maximum time to allow one check to run (ms|s|m|h) (default 0s)
|
||||||
|
--help #Print usage
|
||||||
|
--hostname(-h): string #Container host name
|
||||||
|
--init #Run an init inside the container that forwards signals and reaps processes
|
||||||
|
--interactive(-i) #Keep STDIN open even if not attached
|
||||||
|
--ip: string #IPv4 address (e.g., 172.30.100.104)
|
||||||
|
--ip6: string #IPv6 address (e.g., 2001:db8::33)
|
||||||
|
--ipc: string #IPC mode to use
|
||||||
|
--isolation: string #Container isolation technology
|
||||||
|
--kernel-memory: int #Kernel memory limit
|
||||||
|
--label(-l): string #Set meta data on a container
|
||||||
|
--label-file: string #Read in a line delimited file of labels
|
||||||
|
--link: string #Add link to another container
|
||||||
|
--link-local-ip: string #Container IPv4/IPv6 link-local addresses
|
||||||
|
--log-driver: string #Logging driver for the container
|
||||||
|
--log-opt: string #Log driver options
|
||||||
|
--mac-address: string #Container MAC address (e.g., 92:d0:c6:0a:29:33)
|
||||||
|
--memory(-m): int #Memory limit
|
||||||
|
--memory-reservation: int #Memory soft limit
|
||||||
|
--memory-swap: int #Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
||||||
|
--memory-swappiness: int #Tune container memory swappiness (0 to 100) (default -1)
|
||||||
|
--mount: string #Attach a filesystem mount to the container
|
||||||
|
--name: string #Assign a name to the container
|
||||||
|
--network: string #Connect a container to a network
|
||||||
|
--network-alias: string #Add network-scoped alias for the container
|
||||||
|
--no-healthcheck #Disable any container-specified HEALTHCHECK
|
||||||
|
--oom-kill-disable #Disable OOM Killer
|
||||||
|
--oom-score-adj: int #Tune host's OOM preferences (-1000 to 1000)
|
||||||
|
--pid: string #PID namespace to use
|
||||||
|
--pids-limit: int #Tune container pids limit (set -1 for unlimited)
|
||||||
|
--platform: string #Set platform if server is multi-platform capable
|
||||||
|
--privileged #Give extended privileges to this container
|
||||||
|
--publish(-p): string #Publish a container's port(s) to the host
|
||||||
|
--publish-all(-P) #Publish all exposed ports to random ports
|
||||||
|
--pull: string@"nu-complete docker pull" #Pull image before running ("always", "missing", "never") (default "missing")
|
||||||
|
--quiet(-q) #Suppress the pull output
|
||||||
|
--read-only #Mount the container's root filesystem as read only
|
||||||
|
--restart: string #Restart policy to apply when a container #exits (default "no")
|
||||||
|
--rm #Automatically remove the container when it exits
|
||||||
|
--runtime: string #Runtime to use for this container
|
||||||
|
--security-opt: string #Security Options
|
||||||
|
--shm-size: int #Size of /dev/shm
|
||||||
|
--sig-proxy #Proxy received signals to the process (default true)
|
||||||
|
--stop-signal: string #Signal to stop the container
|
||||||
|
--stop-timeout: int #Timeout (in seconds) to stop a container
|
||||||
|
--storage-opt: string #Storage driver options for the container
|
||||||
|
--sysctl: string #Sysctl options (default map[])
|
||||||
|
--tmpfs: string #Mount a tmpfs directory
|
||||||
|
--tty(-t) #Allocate a pseudo-TTY
|
||||||
|
--ulimit: int #Ulimit options (default [])
|
||||||
|
--user(-u): string #Username or UID (format: <name|uid>[:<group|gid>])
|
||||||
|
--userns: string #User namespace to use
|
||||||
|
--uts: string #UTS namespace to use
|
||||||
|
--volume(-v): string #Bind mount a volume
|
||||||
|
--volume-driver: string #Optional volume driver for the container
|
||||||
|
--volumes-from: string #Mount volumes from the specified container(s)
|
||||||
|
--workdir(-w): string #Working directory inside the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Start one or more stopped containers
|
||||||
|
export extern "docker container start" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--attach(-a) #Attach STDOUT/STDERR and forward signals
|
||||||
|
--interactive(-i) #Attach container's STDIN
|
||||||
|
--detach-keys: string #Override the key sequence for detaching a container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Display a live stream of container(s) resource usage statistics
|
||||||
|
export extern "docker container stats" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--all(-a) #Show all containers (default shows just running)
|
||||||
|
--format: string #Pretty-print images using a Go template
|
||||||
|
--no-stream #Disable streaming stats and only pull the first result
|
||||||
|
--no-trunc #Do not truncate output
|
||||||
|
]
|
||||||
|
|
||||||
|
# Stop one or more running containers
|
||||||
|
export extern "docker container stop" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--time(-t): int #Seconds to wait for stop before killing the container
|
||||||
|
--signal(-s): int #Signal to stop the container
|
||||||
|
]
|
||||||
|
|
||||||
|
# Display the running processes of a container
|
||||||
|
export extern "docker container top" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Unpause all processes within one or more containers
|
||||||
|
export extern "docker container unpause" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Update configuration of one or more containers
|
||||||
|
export extern "docker container update" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
--blkio-weight: int #Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
||||||
|
--cpu-period: int #Limit CPU CFS (Completely Fair Scheduler) period
|
||||||
|
--cpu-quota: int #Limit CPU CFS (Completely Fair Scheduler) quota
|
||||||
|
--cpu-rt-period: int #Limit CPU real-time period in microseconds
|
||||||
|
--cpu-rt-runtime: int #Limit CPU real-time runtime in microseconds
|
||||||
|
--cpu-shares(-c): int #CPU shares (relative weight)
|
||||||
|
--cpus: float #Number of CPUs
|
||||||
|
--cpuset-cpus: string #CPUs in which to allow execution (0-3, 0,1)
|
||||||
|
--cpuset-mems: string #MEMs in which to allow execution (0-3, 0,1)
|
||||||
|
--memory(-m): binary #Memory limit
|
||||||
|
--memory-reservation: binary #Memory soft limit
|
||||||
|
--memory-swap: binary #Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
||||||
|
--pids-limit: int #Tune container pids limit (set -1 for unlimited)
|
||||||
|
--restart: string #Restart policy to apply when a container #exits (default "no")
|
||||||
|
]
|
||||||
|
|
||||||
|
# Block until one or more containers stop, then print their exit codes
|
||||||
|
export extern "docker container wait" [
|
||||||
|
container?: string@"nu-complete docker containers"
|
||||||
|
]
|
||||||
|
|
||||||
|
# Build an image from a Dockerfile
|
||||||
|
export extern "docker image build" [
|
||||||
|
--add-host: string #Add a custom host-to-IP mapping (host:ip)
|
||||||
|
--build-arg: string #Set build-time variables
|
||||||
|
--cache-from: string #Images to consider as cache sources
|
||||||
|
--cgroup-parent: string #Optional parent cgroup for the container
|
||||||
|
--compress #Compress the build context using gzip
|
||||||
|
--file(-f): string@"nu-complete local files" #Name of the Dockerfile (Default is 'PATH/Dockerfile')
|
||||||
|
--iidfile: string #Write the image ID to the file
|
||||||
|
--isolation: string #Container isolation technology
|
||||||
|
--label: string #Set metadata for an image
|
||||||
|
--network: string #Set the networking mode for the RUN instructions during build (default "default")
|
||||||
|
--no-cache #Do not use cache when building the image
|
||||||
|
--platform: string #Set platform if server is multi-platform capable
|
||||||
|
--progress: string #Set type of progress output (auto, plain, tty). Use plain to show container output
|
||||||
|
--pull #Always attempt to pull a newer version of the image
|
||||||
|
--quiet(-q) #Suppress the build output and print image ID on success
|
||||||
|
--secret: string #Secret file to expose to the build (only if BuildKit enabled): id=mysecret,src=/local/secret
|
||||||
|
--ssh: string #SSH agent socket or keys to expose to the build (only if BuildKit enabled)
|
||||||
|
--tag(-t): string #Name and optionally a tag in the 'name:tag' format
|
||||||
|
--target: string #Set the target build stage to build
|
||||||
|
--ulimit: string #Ulimit options (default [])
|
||||||
|
]
|
||||||
|
|
||||||
|
# Show the history of an images
|
||||||
|
export extern "docker image history" [
|
||||||
|
image?: string@"nu-complete docker images"
|
||||||
|
--format: string #Pretty-print images using a Go template
|
||||||
|
--no-trunc #Don't truncate output
|
||||||
|
--quiet(-q) #Only show numeric IDs
|
||||||
|
]
|
||||||
|
|
||||||
|
# Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
|
||||||
|
export extern "docker image tag" [
|
||||||
|
source?: string@"nu-complete docker images"
|
||||||
|
target?: string@"nu-complete docker images"
|
||||||
|
]
|
||||||
|
|
||||||
|
# List images
|
||||||
|
export extern "docker image ls" [
|
||||||
|
--all(-a) #Show all images (default hides intermediate images)
|
||||||
|
--digests #Show digests
|
||||||
|
--filter: string #Filter output based on conditions provided
|
||||||
|
--format: string #Pretty-print images using a Go template
|
||||||
|
--no-trunc #Don't truncate output
|
||||||
|
--quiet(-q) #Only show numeric IDs
|
||||||
|
]
|
||||||
|
|
||||||
|
# Download an image from a registry
|
||||||
|
export extern "docker image pull" [
|
||||||
|
image?: string@"nu-complete docker images"
|
||||||
|
--all-tags(-a) #Push all tags of the specified image
|
||||||
|
--disable-content-trust #Skip image verification (default true)
|
||||||
|
--plataform: string #Set platform if server is multi-platform capable
|
||||||
|
--quiet(-q) #Suppress the push output
|
||||||
|
]
|
||||||
|
|
||||||
|
# Upload an image to a registry
|
||||||
|
export extern "docker image push" [
|
||||||
|
image?: string@"nu-complete docker images"
|
||||||
|
--all-tags(-a) #Push all tags of the specified image
|
||||||
|
--disable-content-trust #Skip image verification (default true)
|
||||||
|
--quiet(-q) #Suppress the push output
|
||||||
|
]
|
||||||
|
|
||||||
|
# Save one or more images to a tar archive (streamed to STDOUT by default)
|
||||||
|
export extern "docker image save" [
|
||||||
|
image?: string@"nu-complete docker images"
|
||||||
|
--output(-o): string #Write to a file, instead of STDOUT
|
||||||
|
]
|
||||||
|
|
||||||
|
# Extended build capabilities with BuildKit
|
||||||
|
export extern "docker buildx" [
|
||||||
|
--builder: string #Override the configured builder instance (default "default")
|
||||||
|
]
|
||||||
|
|
||||||
|
# Stop and remove containers, networks
|
||||||
|
export extern "docker compose down" [
|
||||||
|
--dry-run #Execute command in dry run mode
|
||||||
|
--remove-orphans #Remove containers for services not defined in the Compose file
|
||||||
|
--rmi: string@"nu-complete docker remove image" #Remove images used by services. "local" remove only images that don't have a custom tag ("local"|"all")
|
||||||
|
--timeout(-t): int #Specify a shutdown timeout in seconds
|
||||||
|
--volumes(-v) #Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers
|
||||||
|
]
|
||||||
|
|
||||||
|
# List containers
|
||||||
|
export extern "docker compose ps" [
|
||||||
|
--all(-a) #Show all stopped containers (including those created by the run command)
|
||||||
|
--dry-run #Execute command in dry run mode
|
||||||
|
--filter: string #Filter services by a property (supported filters: status)
|
||||||
|
--format: string #Format output using a custom template: 'table': Print output in table; format with column headers (default) 'table TEMPLATE': Print output in table; format using the given Go template 'json': Print in JSON format; 'TEMPLATE': Print output using the given Go template; Refer to https://docs.docker.com/go/formatting/ for more information about formatting output with templates (default "table")
|
||||||
|
--no-truncate #Don't truncate output
|
||||||
|
--orphans #Include orphaned services (not declared by project) (default true)
|
||||||
|
--quite(-q) #Only display IDs
|
||||||
|
--services #Display services
|
||||||
|
--status: string@"nu-complete docker compose service status" #Filter services by status. Values: [paused | restarting | removing | running | dead | created | exited]
|
||||||
|
]
|
||||||
|
|
||||||
|
# Stop containers
|
||||||
|
export extern "docker compose stop" [
|
||||||
|
--dry-run #Execute command in dry run mode
|
||||||
|
--timeout(-t): int #Specify a shutdown timeout in seconds
|
||||||
|
]
|
||||||
|
|
||||||
|
# Restart service containers
|
||||||
|
export extern "docker compose restart" [
|
||||||
|
--dry-run #Execute command in dry run mode
|
||||||
|
--no-deps #Don't restart dependent services
|
||||||
|
--timeout(-t): int #Specify a shutdown timeout in seconds
|
||||||
|
]
|
||||||
|
|
||||||
|
# Create and start containers
|
||||||
|
export extern "docker compose up" [
|
||||||
|
--abort-on-container-exit #Stops all containers if any container was stopped. Incompatible with -d/--detach
|
||||||
|
--abort-on-container-failure #Stops all containers if any container had a non-zero exit code. Incompatible with -d/--detach
|
||||||
|
--always-recreate-deps #Recreate dependent containers. Incompatible with --no-recreate
|
||||||
|
--attach: string #Restrict attaching to the specified services. Incompatible with --attach-dependencies
|
||||||
|
--attach-dependencies #Automatically attach to log output of all dependent services
|
||||||
|
--build #Build images before starting containers
|
||||||
|
--detach(-d) #Detached mode: Run containers in the background
|
||||||
|
--dry-run #Execute command in dry run mode
|
||||||
|
--exit-code-from: string #Return the exit code of the selected service container. Implies --abort-on-container-exit
|
||||||
|
--force-recreate #Recreate containers even if their configuration and image haven't changed
|
||||||
|
--menu #Enable interactive shortcuts when running attached. Incompatible with --detach. Can also be enable/disable
|
||||||
|
--no-attach: string #Do not attach (stream logs) to the specified services
|
||||||
|
--no-build #Don't build an image, even if it's policy
|
||||||
|
--no-color #Produce monochrome output
|
||||||
|
--no-deps #Don't start linked services
|
||||||
|
--no-log-prefix #Don't print prefix in logs
|
||||||
|
--no-recreate #If containers already exist, don't recreate them. Incompatible with --force-recreate
|
||||||
|
--no-start #Don't start the services after creating them
|
||||||
|
--pull: string@"nu-complete docker pull" #Pull image before running ("always"|"missing"|"never") (default "policy")
|
||||||
|
--quite-pull #Pull without printing progress information
|
||||||
|
--remove-orphans #Remove containers for services not defined in the Compose file
|
||||||
|
--renew-anon-volumes(-V) #Recreate anonymous volumes instead of retrieving data from the previous containers
|
||||||
|
# --scale: scale #Scale SERVICE to NUM instances. Overrides the scale setting in the Compose file if present
|
||||||
|
--timeout(-t): int #Use this timeout in seconds for container shutdown when attached or when containers are already running
|
||||||
|
--timestamps #Show timestamps
|
||||||
|
--wait #Wait for services to be running|healthy. Implies detached mode
|
||||||
|
--wait-timeout: int #Maximum duration to wait for the project to be running|healthy
|
||||||
|
--watch(-w) #Watch source code and rebuild|refresh containers when files are updated
|
||||||
|
]
|
||||||
|
|
||||||
|
# An open-source container management platform.
|
||||||
|
export extern "docker" [
|
||||||
|
--config: string #Location of client config files (default "/root/.docker")
|
||||||
|
--context(-c): string #Name of the context to use to connect to the daemon (overrides DOCKER_HOST env var and default context set with "docker context use")
|
||||||
|
--debug(-D) #Enable debug mode
|
||||||
|
--host(-H): string #Daemon socket(s) to connect to
|
||||||
|
--log-level(-l): string #Set the logging level ("debug"|"info"|"warn"|"error"|"fatal")
|
||||||
|
--tls #Use TLS; implied by --tlsverify
|
||||||
|
--tlscacert: string #Trust certs signed only by this CA
|
||||||
|
--tlscert: string #Path to TLS certificate file
|
||||||
|
--tlskey: string #Path to TLS key file
|
||||||
|
--tlsverify #Use TLS and verify the remote
|
||||||
|
--version(-v) #Print version information and quit
|
||||||
|
]
|
||||||
|
|
||||||
|
# Attach local standard input, output, and error streams to a running container
|
||||||
|
export alias "docker attach" = docker container attach
|
||||||
|
# Create a new image from a container's changes
|
||||||
|
export alias "docker commit" = docker container commit
|
||||||
|
export alias "docker cp" = docker container cp
|
||||||
|
# Create a new container
|
||||||
|
export alias "docker create" = docker container create
|
||||||
|
# Inspect changes to files or directories on a container's filesystem
|
||||||
|
export alias "docker diff" = docker container diff
|
||||||
|
# Execute a command in a running container
|
||||||
|
export alias "docker exec" = docker container exec
|
||||||
|
# Export a container's filesystem as a tar archive
|
||||||
|
export alias "docker export" = docker container export
|
||||||
|
# Display detailed information on one or more containers
|
||||||
|
export alias "docker inspect" = docker container inspect
|
||||||
|
# Kill one or more running containers
|
||||||
|
export alias "docker kill" = docker container kill
|
||||||
|
# Fetch the logs of a container
|
||||||
|
export alias "docker logs" = docker container logs
|
||||||
|
# Pause all processes within one or more containers
|
||||||
|
export alias "docker pause" = docker container pause
|
||||||
|
# List port mappings or a specific mapping for the container
|
||||||
|
export alias "docker port" = docker container port
|
||||||
|
# Rename a container
|
||||||
|
export alias "docker rename" = docker container rename
|
||||||
|
# Restart one or more containers
|
||||||
|
export alias "docker restart" = docker container restart
|
||||||
|
# List containers
|
||||||
|
export alias "docker ps" = docker container ls
|
||||||
|
# Remove one or more containers
|
||||||
|
export alias "docker rm" = docker container rm
|
||||||
|
# Run a command in a new container
|
||||||
|
export alias "docker run" = docker container run
|
||||||
|
# Start one or more stopped containers
|
||||||
|
export alias "docker start" = docker container start
|
||||||
|
# Display a live stream of container(s) resource usage statistics
|
||||||
|
export alias "docker stats" = docker container stats
|
||||||
|
# Stop one or more running containers
|
||||||
|
export alias "docker stop" = docker container stop
|
||||||
|
# Display the running processes of a container
|
||||||
|
export alias "docker top" = docker container top
|
||||||
|
# Unpause all processes within one or more containers
|
||||||
|
export alias "docker unpause" = docker container unpause
|
||||||
|
# Update configuration of one or more containers
|
||||||
|
export alias "docker update" = docker container update
|
||||||
|
# Block until one or more containers stop, then print their exit codes
|
||||||
|
export alias "docker wait" = docker container wait
|
||||||
|
|
||||||
|
# Build an image from a Dockerfile
|
||||||
|
export alias "docker build" = docker image build
|
||||||
|
# Show the history of an image
|
||||||
|
export alias "docker history" = docker image history
|
||||||
|
# Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
|
||||||
|
export alias "docker tag" = docker image tag
|
||||||
|
# List images
|
||||||
|
export alias "docker images" = docker image ls
|
||||||
|
# Remove one or more images
|
||||||
|
export alias "docker rmi" = docker image rm
|
||||||
|
# Download an image from a registry
|
||||||
|
export alias "docker pull" = docker image pull
|
||||||
|
# Upload an image to a registry
|
||||||
|
export alias "docker push" = docker image push
|
||||||
|
# Save one or more images to a tar archive (streamed to STDOUT by default)
|
||||||
|
export alias "docker save" = docker image save
|
||||||
|
|
||||||
|
# Inspect changes to files or directories on a container's filesystem
|
||||||
|
export alias "docker events" = docker system events
|
@ -1,681 +0,0 @@
|
|||||||
# https://github.com/nushell/nu_scripts/blob/main/custom-completions/docker/docker-completions.nu
|
|
||||||
# remove docker from extern to avoid `$ docker docker command`
|
|
||||||
|
|
||||||
def "nu-complete docker containers" [] {
|
|
||||||
^docker ps -a --format "{{.ID}} {{.Names}}" | lines
|
|
||||||
| parse "{value} {description}"
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker images" [] {
|
|
||||||
^docker images --format "{{.ID}} {{.Repository}}" | lines
|
|
||||||
| parse "{value} {description}"
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker run" [] {
|
|
||||||
(nu-complete docker images)
|
|
||||||
| append (nu-complete docker containers)
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker pull" [] {
|
|
||||||
[always, missing, never]
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker remove image" [] {
|
|
||||||
[local, all]
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete local files" [] {
|
|
||||||
^ls | lines
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker compose ps" [] {
|
|
||||||
^docker compose ps -a --format "{{.ID}} {{.Names}}" | lines
|
|
||||||
| parse "{value} {description}"
|
|
||||||
}
|
|
||||||
|
|
||||||
def "nu-complete docker compose service status" [] {
|
|
||||||
[paused restarting removing running dead created exited]
|
|
||||||
}
|
|
||||||
|
|
||||||
# Log in to a Docker registry
|
|
||||||
export extern login [
|
|
||||||
server?: string # Docker registry URL
|
|
||||||
--password(-p): string # Password
|
|
||||||
--password-stdin # Take the password from stdin
|
|
||||||
--username(-u): string # Username
|
|
||||||
]
|
|
||||||
|
|
||||||
# Log out from a Docker registry
|
|
||||||
export extern logout [
|
|
||||||
server?: string # Docker registry URL
|
|
||||||
]
|
|
||||||
|
|
||||||
# Search Docker Hub for images
|
|
||||||
export extern search [
|
|
||||||
term?: string
|
|
||||||
--filter(-f): string # Filter output based on conditions provided
|
|
||||||
--format: string # Pretty-print search using a Go template
|
|
||||||
--limit: int # Max number of search results
|
|
||||||
--no-trunc # Don't truncate output
|
|
||||||
]
|
|
||||||
|
|
||||||
# Show the docker version information
|
|
||||||
export extern version [
|
|
||||||
--format(-f): string # Format the output using the given Go template
|
|
||||||
--kubeconfig: string # Kubernetes config file
|
|
||||||
]
|
|
||||||
|
|
||||||
# Inspect changes to files or directories on a container's filesystem
|
|
||||||
export extern "system events" [
|
|
||||||
--filter(-f): string # Filter output based on conditions provided
|
|
||||||
--format: string # Pretty-print images using a Go template
|
|
||||||
--since: string # Show all events created since timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
|
||||||
--until: string # Stream events until this timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
|
||||||
]
|
|
||||||
|
|
||||||
# Attach local standard input, output, and error streams to a running container
|
|
||||||
export extern "container attach" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--detach-keys:string # Override the key sequence for detaching a container
|
|
||||||
--no-stdin # Do not attach STDIN
|
|
||||||
--sig-proxy # Proxy all received signals to the process
|
|
||||||
]
|
|
||||||
|
|
||||||
# Create a new image from a container's changes
|
|
||||||
export extern "container commit" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--author(-a): string # Author (e.g., "John Hannibal Smith <hannibal@a-team.com>"
|
|
||||||
--change(-c): string # Apply Dockerfile instruction to the created image
|
|
||||||
--message(-m): string # Commit message
|
|
||||||
--pause(-p) # Pause container during commit (default true)
|
|
||||||
]
|
|
||||||
|
|
||||||
# Create a new container
|
|
||||||
export extern "container create" [
|
|
||||||
image?: string@"nu-complete docker images" # The image to create the container from
|
|
||||||
command?: string # Command to run inside the container
|
|
||||||
...args: string
|
|
||||||
--add-host: string # Add a custom host-to-IP mapping (host:ip)
|
|
||||||
--annotation: string # Add an annotation to the container (passed through to the OCI runtime) (default map[])
|
|
||||||
--attach: string # Attach to STDIN, STDOUT or STDERR
|
|
||||||
--blkio-weight: int # Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
|
||||||
--blkio-weight-device: string # Block IO weight (relative device weight) (default [])
|
|
||||||
--cap-add: string # Add Linux capabilities
|
|
||||||
--cap-drop: string # Drop Linux capabilities
|
|
||||||
--cgroup-parent: string # Optional parent cgroup for the container
|
|
||||||
--cgroupns: string # Cgroup namespace to use (host|private)
|
|
||||||
--cidfile: string # Write the container ID to the file
|
|
||||||
--cpu-period: int # Limit CPU CFS (Completely Fair Scheduler) period
|
|
||||||
--cpu-quota: int # Limit CPU CFS (Completely Fair Scheduler) quota
|
|
||||||
--cpu-rt-period: int # Limit CPU real-time period in microseconds
|
|
||||||
--cpu-rt-runtime: int # Limit CPU real-time runtime in microseconds
|
|
||||||
--cpu-shares(-c): int # CPU shares (relative weight)
|
|
||||||
--cpus: int # Number of CPUs
|
|
||||||
--cpuset-cpus: string # CPUs in which to allow execution (0-3, 0,1)
|
|
||||||
--cpuset-mems: string # MEMs in which to allow execution (0-3, 0,1)
|
|
||||||
--detach(-d) # Run container in background and print container ID
|
|
||||||
--detach-keys: string # Override the key sequence for detaching a container
|
|
||||||
--device: string # Add a host device to the container
|
|
||||||
--device-cgroup-rule: string # Add a rule to the cgroup allowed devices list
|
|
||||||
--device-read-bps: int # Limit read rate (bytes per second) from a device (default [])
|
|
||||||
--device-read-iops: int # Limit read rate (IO per second) from a device (default [])
|
|
||||||
--device-write-bps: int # Limit write rate (bytes per second) to a device (default [])
|
|
||||||
--device-write-iops: int # Limit write rate (IO per second) to a device (default [])
|
|
||||||
--disable-content-trust # Skip image verification (default true)
|
|
||||||
--dns: int # Set custom DNS servers
|
|
||||||
--dns-option: string # Set DNS options
|
|
||||||
--dns-search: string # Set custom DNS search domains
|
|
||||||
--domainname: string # Container NIS domain name
|
|
||||||
--entrypoint: string # Overwrite the default ENTRYPOINT of the image
|
|
||||||
--env(-e): string # Set environment variables
|
|
||||||
--env-file: string # Read in a file of environment variables
|
|
||||||
--expose: string # Expose a port or a range of ports
|
|
||||||
--gpus: string # GPU devices to add to the container ('all' to pass all GPUs)
|
|
||||||
--group-add: string # Add additional groups to join
|
|
||||||
--health-cmd: string # Command to run to check health
|
|
||||||
--health-interval: duration # Time between running the check (ms|s|m|h) (default 0s)
|
|
||||||
--health-retries: int # Consecutive failures needed to report unhealthy
|
|
||||||
--health-start-interval: duration # Time between running the check during the start period (ms|s|m|h) (default 0s)
|
|
||||||
--health-start-period: duration # Start period for the container to initialize before starting health-retries countdown (ms|s|m|h) (default 0s)
|
|
||||||
--health-timeout: duration # Maximum time to allow one check to run (ms|s|m|h) (default 0s)
|
|
||||||
--help # Print usage
|
|
||||||
--hostname(-h): string # Container host name
|
|
||||||
--init # Run an init inside the container that forwards signals and reaps processes
|
|
||||||
--interactive(-i) # Keep STDIN open even if not attached
|
|
||||||
--ip: string # IPv4 address (e.g., 172.30.100.104)
|
|
||||||
--ip6: string # IPv6 address (e.g., 2001:db8::33)
|
|
||||||
--ipc: string # IPC mode to use
|
|
||||||
--isolation: string # Container isolation technology
|
|
||||||
--kernel-memory: int # Kernel memory limit
|
|
||||||
--label(-l): string # Set meta data on a container
|
|
||||||
--label-file: string # Read in a line delimited file of labels
|
|
||||||
--link: string # Add link to another container
|
|
||||||
--link-local-ip: string # Container IPv4/IPv6 link-local addresses
|
|
||||||
--log-driver: string # Logging driver for the container
|
|
||||||
--log-opt: string # Log driver options
|
|
||||||
--mac-address: string # Container MAC address (e.g., 92:d0:c6:0a:29:33)
|
|
||||||
--memory(-m): int # Memory limit
|
|
||||||
--memory-reservation: int # Memory soft limit
|
|
||||||
--memory-swap: int # Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
|
||||||
--memory-swappiness: int # Tune container memory swappiness (0 to 100) (default -1)
|
|
||||||
--mount: string # Attach a filesystem mount to the container
|
|
||||||
--name: string # Assign a name to the container
|
|
||||||
--network: string # Connect a container to a network
|
|
||||||
--network-alias: string # Add network-scoped alias for the container
|
|
||||||
--no-healthcheck # Disable any container-specified HEALTHCHECK
|
|
||||||
--oom-kill-disable # Disable OOM Killer
|
|
||||||
--oom-score-adj: int # Tune host's OOM preferences (-1000 to 1000)
|
|
||||||
--pid: string # PID namespace to use
|
|
||||||
--pids-limit: int # Tune container pids limit (set -1 for unlimited)
|
|
||||||
--platform: string # Set platform if server is multi-platform capable
|
|
||||||
--privileged # Give extended privileges to this container
|
|
||||||
--publish(-p): string # Publish a container's port(s) to the host
|
|
||||||
--publish-all(-P) # Publish all exposed ports to random ports
|
|
||||||
--pull: string@"nu-complete docker pull" # Pull image before running ("always", "missing", "never") (default "missing")
|
|
||||||
--quiet(-q) # Suppress the pull output
|
|
||||||
--read-only # Mount the container's root filesystem as read only
|
|
||||||
--restart: string # Restart policy to apply when a container exits (default "no")
|
|
||||||
--rm # Automatically remove the container when it exits
|
|
||||||
--runtime: string # Runtime to use for this container
|
|
||||||
--security-opt: string # Security Options
|
|
||||||
--shm-size: int # Size of /dev/shm
|
|
||||||
--sig-proxy # Proxy received signals to the process (default true)
|
|
||||||
--stop-signal: string # Signal to stop the container
|
|
||||||
--stop-timeout: int # Timeout (in seconds) to stop a container
|
|
||||||
--storage-opt: string # Storage driver options for the container
|
|
||||||
--sysctl: string # Sysctl options (default map[])
|
|
||||||
--tmpfs: string # Mount a tmpfs directory
|
|
||||||
--tty(-t) # Allocate a pseudo-TTY
|
|
||||||
--ulimit: int # Ulimit options (default [])
|
|
||||||
--user(-u): string # Username or UID (format: <name|uid>[:<group|gid>])
|
|
||||||
--userns: string # User namespace to use
|
|
||||||
--uts: string # UTS namespace to use
|
|
||||||
--volume(-v): string # Bind mount a volume
|
|
||||||
--volume-driver: string # Optional volume driver for the container
|
|
||||||
--volumes-from: string # Mount volumes from the specified container(s)
|
|
||||||
--workdir(-w): string # Working directory inside the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Inspect changes to files or directories on a container's filesystem
|
|
||||||
export extern "container diff" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Run a command in a running container
|
|
||||||
export extern "container exec" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--detach(-d) # Detached mode: run command in the background
|
|
||||||
--env(-e): string # Set environment variables
|
|
||||||
--interactive(-i) # Keep STDIN open even if not attached
|
|
||||||
--privileged # Give extended privileges to the command
|
|
||||||
--tty(-t) # Allocate a pseudo-TTY
|
|
||||||
--user(-u): string # Username or UID (format: <name|uid>[:<group|gid>])
|
|
||||||
--workdir(-w): string # Working directory inside the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Export a container's filesystem as a tar archive
|
|
||||||
export extern "container export" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--output(-o): string # Write to a file, instead of STDOUT
|
|
||||||
]
|
|
||||||
|
|
||||||
# Display detailed information on one or more containers
|
|
||||||
export extern "container inspect" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--format(-f):string # Format the output using the given Go template
|
|
||||||
--size(-s) # Display total file sizes
|
|
||||||
--type:string # Return JSON for specified type
|
|
||||||
]
|
|
||||||
|
|
||||||
# Kill one or more running containers
|
|
||||||
export extern "container kill" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--signal(-s):string # Signal to send to the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Fetch the logs of a container
|
|
||||||
export extern "container logs" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--details # Show extra details provided to logs
|
|
||||||
--follow(-f) # Follow log output
|
|
||||||
--since: string # Show logs since timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
|
||||||
--tail(-n): string # Number of lines to show from the end of the logs
|
|
||||||
--timestamps(-t) # Show timestamps
|
|
||||||
--until: string # Show logs before a timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes)
|
|
||||||
]
|
|
||||||
|
|
||||||
# List containers
|
|
||||||
export extern "container ls" [
|
|
||||||
--all(-a) # Show all containers (default shows just running)
|
|
||||||
--filter: string # Filter output based on conditions provided
|
|
||||||
--format: string # Pretty-print containers using a Go template
|
|
||||||
--last(-n): int # Show n last created containers (includes all states) (default -1)
|
|
||||||
--latest(-l) # Show the latest created container (includes all states)
|
|
||||||
--no-trunc # Don't truncate output
|
|
||||||
--quiet(-q) # Only display numeric IDs
|
|
||||||
--size(-s) # Display total file sizes
|
|
||||||
]
|
|
||||||
|
|
||||||
# Pause all processes within one or more containers
|
|
||||||
export extern "container pause" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Remove all stopped containers
|
|
||||||
export extern "container prune" [
|
|
||||||
--filter: string # Provide filter values (e.g. 'until=24h')
|
|
||||||
--force(-f) # Do not prompt for confirmation
|
|
||||||
]
|
|
||||||
|
|
||||||
# List port mappings or a specific mapping for the container
|
|
||||||
export extern "container port" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Rename a container
|
|
||||||
export extern "container rename" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
name?: string
|
|
||||||
]
|
|
||||||
|
|
||||||
# Restart one or more containers
|
|
||||||
export extern "container restart" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--time(-t): int # Seconds to wait for stop before killing the container
|
|
||||||
--signal(-s): string # Signal to stop the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Remove one or more containers
|
|
||||||
export extern "container rm" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Run a command in a new container
|
|
||||||
export extern "container run" [
|
|
||||||
image?: string@"nu-complete docker run" # The image to create the container from
|
|
||||||
command?: string # Command to run inside the container
|
|
||||||
...args: string
|
|
||||||
--add-host: string # Add a custom host-to-IP mapping (host:ip)
|
|
||||||
--annotation: string # Add an annotation to the container (passed through to the OCI runtime) (default map[])
|
|
||||||
--attach: string # Attach to STDIN, STDOUT or STDERR
|
|
||||||
--blkio-weight: int # Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
|
||||||
--blkio-weight-device: string # Block IO weight (relative device weight) (default [])
|
|
||||||
--cap-add: string # Add Linux capabilities
|
|
||||||
--cap-drop: string # Drop Linux capabilities
|
|
||||||
--cgroup-parent: string # Optional parent cgroup for the container
|
|
||||||
--cgroupns: string # Cgroup namespace to use (host|private)
|
|
||||||
--cidfile: string # Write the container ID to the file
|
|
||||||
--cpu-period: int # Limit CPU CFS (Completely Fair Scheduler) period
|
|
||||||
--cpu-quota: int # Limit CPU CFS (Completely Fair Scheduler) quota
|
|
||||||
--cpu-rt-period: int # Limit CPU real-time period in microseconds
|
|
||||||
--cpu-rt-runtime: int # Limit CPU real-time runtime in microseconds
|
|
||||||
--cpu-shares(-c): int # CPU shares (relative weight)
|
|
||||||
--cpus: int # Number of CPUs
|
|
||||||
--cpuset-cpus: string # CPUs in which to allow execution (0-3, 0,1)
|
|
||||||
--cpuset-mems: string # MEMs in which to allow execution (0-3, 0,1)
|
|
||||||
--detach(-d) # Run container in background and print container ID
|
|
||||||
--detach-keys: string # Override the key sequence for detaching a container
|
|
||||||
--device: string # Add a host device to the container
|
|
||||||
--device-cgroup-rule: string # Add a rule to the cgroup allowed devices int
|
|
||||||
--device-read-bps: int # Limit read rate (bytes per second) from a device (default [])
|
|
||||||
--device-read-iops: int # Limit read rate (IO per second) from a device (default [])
|
|
||||||
--device-write-bps: int # Limit write rate (bytes per second) to a device (default [])
|
|
||||||
--device-write-iops: int # Limit write rate (IO per second) to a device (default [])
|
|
||||||
--disable-content-trust # Skip image verification (default true)
|
|
||||||
--dns: int # Set custom DNS servers
|
|
||||||
--dns-option: string # Set DNS options
|
|
||||||
--dns-search: string # Set custom DNS search domains
|
|
||||||
--domainname: string # Container NIS domain name
|
|
||||||
--entrypoint: string # Overwrite the default ENTRYPOINT of the image
|
|
||||||
--env(-e): string # Set environment variables
|
|
||||||
--env-file: string # Read in a file of environment variables
|
|
||||||
--expose: string # Expose a port or a range of ports
|
|
||||||
--gpus: string # GPU devices to add to the container ('all' to pass all GPUs)
|
|
||||||
--group-add: string # Add additional groups to join
|
|
||||||
--health-cmd: string # Command to run to check health
|
|
||||||
--health-interval: duration # Time between running the check (ms|s|m|h) (default 0s)
|
|
||||||
--health-retries: int # Consecutive failures needed to report unhealthy
|
|
||||||
--health-start-interval: duration # Time between running the check during the start period (ms|s|m|h) (default 0s)
|
|
||||||
--health-start-period: duration # Start period for the container to initialize before starting health-retries countdown (ms|s|m|h) (default 0s)
|
|
||||||
--health-timeout: duration # Maximum time to allow one check to run (ms|s|m|h) (default 0s)
|
|
||||||
--help # Print usage
|
|
||||||
--hostname(-h): string # Container host name
|
|
||||||
--init # Run an init inside the container that forwards signals and reaps processes
|
|
||||||
--interactive(-i) # Keep STDIN open even if not attached
|
|
||||||
--ip: string # IPv4 address (e.g., 172.30.100.104)
|
|
||||||
--ip6: string # IPv6 address (e.g., 2001:db8::33)
|
|
||||||
--ipc: string # IPC mode to use
|
|
||||||
--isolation: string # Container isolation technology
|
|
||||||
--kernel-memory: int # Kernel memory limit
|
|
||||||
--label(-l): string # Set meta data on a container
|
|
||||||
--label-file: string # Read in a line delimited file of labels
|
|
||||||
--link: string # Add link to another container
|
|
||||||
--link-local-ip: string # Container IPv4/IPv6 link-local addresses
|
|
||||||
--log-driver: string # Logging driver for the container
|
|
||||||
--log-opt: string # Log driver options
|
|
||||||
--mac-address: string # Container MAC address (e.g., 92:d0:c6:0a:29:33)
|
|
||||||
--memory(-m): int # Memory limit
|
|
||||||
--memory-reservation: int # Memory soft limit
|
|
||||||
--memory-swap: int # Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
|
||||||
--memory-swappiness: int # Tune container memory swappiness (0 to 100) (default -1)
|
|
||||||
--mount: string # Attach a filesystem mount to the container
|
|
||||||
--name: string # Assign a name to the container
|
|
||||||
--network: string # Connect a container to a network
|
|
||||||
--network-alias: string # Add network-scoped alias for the container
|
|
||||||
--no-healthcheck # Disable any container-specified HEALTHCHECK
|
|
||||||
--oom-kill-disable # Disable OOM Killer
|
|
||||||
--oom-score-adj: int # Tune host's OOM preferences (-1000 to 1000)
|
|
||||||
--pid: string # PID namespace to use
|
|
||||||
--pids-limit: int # Tune container pids limit (set -1 for unlimited)
|
|
||||||
--platform: string # Set platform if server is multi-platform capable
|
|
||||||
--privileged # Give extended privileges to this container
|
|
||||||
--publish(-p): string # Publish a container's port(s) to the host
|
|
||||||
--publish-all(-P) # Publish all exposed ports to random ports
|
|
||||||
--pull: string@"nu-complete docker pull" # Pull image before running ("always", "missing", "never") (default "missing")
|
|
||||||
--quiet(-q) # Suppress the pull output
|
|
||||||
--read-only # Mount the container's root filesystem as read only
|
|
||||||
--restart: string # Restart policy to apply when a container exits (default "no")
|
|
||||||
--rm # Automatically remove the container when it exits
|
|
||||||
--runtime: string # Runtime to use for this container
|
|
||||||
--security-opt: string # Security Options
|
|
||||||
--shm-size: int # Size of /dev/shm
|
|
||||||
--sig-proxy # Proxy received signals to the process (default true)
|
|
||||||
--stop-signal: string # Signal to stop the container
|
|
||||||
--stop-timeout: int # Timeout (in seconds) to stop a container
|
|
||||||
--storage-opt: string # Storage driver options for the container
|
|
||||||
--sysctl: string # Sysctl options (default map[])
|
|
||||||
--tmpfs: string # Mount a tmpfs directory
|
|
||||||
--tty(-t) # Allocate a pseudo-TTY
|
|
||||||
--ulimit: int # Ulimit options (default [])
|
|
||||||
--user(-u): string # Username or UID (format: <name|uid>[:<group|gid>])
|
|
||||||
--userns: string # User namespace to use
|
|
||||||
--uts: string # UTS namespace to use
|
|
||||||
--volume(-v): string # Bind mount a volume
|
|
||||||
--volume-driver: string # Optional volume driver for the container
|
|
||||||
--volumes-from: string # Mount volumes from the specified container(s)
|
|
||||||
--workdir(-w): string # Working directory inside the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Start one or more stopped containers
|
|
||||||
export extern "container start" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--attach(-a) # Attach STDOUT/STDERR and forward signals
|
|
||||||
--interactive(-i) # Attach container's STDIN
|
|
||||||
--detach-keys: string # Override the key sequence for detaching a container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Display a live stream of container(s) resource usage statistics
|
|
||||||
export extern "container stats" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--all(-a) # Show all containers (default shows just running)
|
|
||||||
--format: string # Pretty-print images using a Go template
|
|
||||||
--no-stream # Disable streaming stats and only pull the first result
|
|
||||||
--no-trunc # Do not truncate output
|
|
||||||
]
|
|
||||||
|
|
||||||
# Stop one or more running containers
|
|
||||||
export extern "container stop" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--time(-t): int # Seconds to wait for stop before killing the container
|
|
||||||
--signal(-s): int # Signal to stop the container
|
|
||||||
]
|
|
||||||
|
|
||||||
# Display the running processes of a container
|
|
||||||
export extern "container top" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Unpause all processes within one or more containers
|
|
||||||
export extern "container unpause" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Update configuration of one or more containers
|
|
||||||
export extern "container update" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
--blkio-weight: int # Block IO (relative weight), between 10 and 1000, or 0 to disable (default 0)
|
|
||||||
--cpu-period: int # Limit CPU CFS (Completely Fair Scheduler) period
|
|
||||||
--cpu-quota: int # Limit CPU CFS (Completely Fair Scheduler) quota
|
|
||||||
--cpu-rt-period: int # Limit CPU real-time period in microseconds
|
|
||||||
--cpu-rt-runtime: int # Limit CPU real-time runtime in microseconds
|
|
||||||
--cpu-shares(-c): int # CPU shares (relative weight)
|
|
||||||
--cpus: float # Number of CPUs
|
|
||||||
--cpuset-cpus: string # CPUs in which to allow execution (0-3, 0,1)
|
|
||||||
--cpuset-mems: string # MEMs in which to allow execution (0-3, 0,1)
|
|
||||||
--memory(-m): binary # Memory limit
|
|
||||||
--memory-reservation: binary # Memory soft limit
|
|
||||||
--memory-swap: binary # Swap limit equal to memory plus swap: '-1' to enable unlimited swap
|
|
||||||
--pids-limit: int # Tune container pids limit (set -1 for unlimited)
|
|
||||||
--restart: string # Restart policy to apply when a container exits (default "no")
|
|
||||||
]
|
|
||||||
|
|
||||||
# Block until one or more containers stop, then print their exit codes
|
|
||||||
export extern "container wait" [
|
|
||||||
container?: string@"nu-complete docker containers"
|
|
||||||
]
|
|
||||||
|
|
||||||
# Build an image from a Dockerfile
|
|
||||||
export extern "image build" [
|
|
||||||
--add-host: string # Add a custom host-to-IP mapping (host:ip)
|
|
||||||
--build-arg: string # Set build-time variables
|
|
||||||
--cache-from: string # Images to consider as cache sources
|
|
||||||
--cgroup-parent: string # Optional parent cgroup for the container
|
|
||||||
--compress # Compress the build context using gzip
|
|
||||||
--file(-f): string@"nu-complete local files" # Name of the Dockerfile (Default is 'PATH/Dockerfile')
|
|
||||||
--iidfile: string # Write the image ID to the file
|
|
||||||
--isolation: string # Container isolation technology
|
|
||||||
--label: string # Set metadata for an image
|
|
||||||
--network: string # Set the networking mode for the RUN instructions during build (default "default")
|
|
||||||
--no-cache # Do not use cache when building the image
|
|
||||||
--platform: string # Set platform if server is multi-platform capable
|
|
||||||
--progress: string # Set type of progress output (auto, plain, tty). Use plain to show container output
|
|
||||||
--pull # Always attempt to pull a newer version of the image
|
|
||||||
--quiet(-q) # Suppress the build output and print image ID on success
|
|
||||||
--secret: string # Secret file to expose to the build (only if BuildKit enabled): id=mysecret,src=/local/secret
|
|
||||||
--ssh: string # SSH agent socket or keys to expose to the build (only if BuildKit enabled)
|
|
||||||
--tag(-t): string # Name and optionally a tag in the 'name:tag' format
|
|
||||||
--target: string # Set the target build stage to build
|
|
||||||
--ulimit: string # Ulimit options (default [])
|
|
||||||
]
|
|
||||||
|
|
||||||
# Show the history of an images
|
|
||||||
export extern "image history" [
|
|
||||||
image?: string@"nu-complete docker images"
|
|
||||||
--format: string # Pretty-print images using a Go template
|
|
||||||
--no-trunc # Don't truncate output
|
|
||||||
--quiet(-q) # Only show numeric IDs
|
|
||||||
]
|
|
||||||
|
|
||||||
# Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
|
|
||||||
export extern "image tag" [
|
|
||||||
source?: string@"nu-complete docker images"
|
|
||||||
target?: string@"nu-complete docker images"
|
|
||||||
]
|
|
||||||
|
|
||||||
# List images
|
|
||||||
export extern "image ls" [
|
|
||||||
--all(-a) # Show all images (default hides intermediate images)
|
|
||||||
--digests # Show digests
|
|
||||||
--filter: string # Filter output based on conditions provided
|
|
||||||
--format: string # Pretty-print images using a Go template
|
|
||||||
--no-trunc # Don't truncate output
|
|
||||||
--quiet(-q) # Only show numeric IDs
|
|
||||||
]
|
|
||||||
|
|
||||||
# Download an image from a registry
|
|
||||||
export extern "image pull" [
|
|
||||||
image?: string@"nu-complete docker images"
|
|
||||||
--all-tags(-a) # Push all tags of the specified image
|
|
||||||
--disable-content-trust # Skip image verification (default true)
|
|
||||||
--plataform: string # Set platform if server is multi-platform capable
|
|
||||||
--quiet(-q) # Suppress the push output
|
|
||||||
]
|
|
||||||
|
|
||||||
# Upload an image to a registry
|
|
||||||
export extern "image push" [
|
|
||||||
image?: string@"nu-complete docker images"
|
|
||||||
--all-tags(-a) # Push all tags of the specified image
|
|
||||||
--disable-content-trust # Skip image verification (default true)
|
|
||||||
--quiet(-q) # Suppress the push output
|
|
||||||
]
|
|
||||||
|
|
||||||
# Save one or more images to a tar archive (streamed to STDOUT by default)
|
|
||||||
export extern "image save" [
|
|
||||||
image?: string@"nu-complete docker images"
|
|
||||||
--output(-o): string # Write to a file, instead of STDOUT
|
|
||||||
]
|
|
||||||
|
|
||||||
# Extended build capabilities with BuildKit
|
|
||||||
export extern buildx [
|
|
||||||
--builder: string # Override the configured builder instance (default "default")
|
|
||||||
]
|
|
||||||
|
|
||||||
# Stop and remove containers, networks
|
|
||||||
export extern "compose down" [
|
|
||||||
--dry-run # Execute command in dry run mode
|
|
||||||
--remove-orphans # Remove containers for services not defined in the Compose file
|
|
||||||
--rmi: string@"nu-complete docker remove image" # Remove images used by services. "local" remove only images that don't have a custom tag ("local"|"all")
|
|
||||||
--timeout(-t): int # Specify a shutdown timeout in seconds
|
|
||||||
--volumes(-v) # Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers
|
|
||||||
]
|
|
||||||
|
|
||||||
# List containers
|
|
||||||
export extern "compose ps" [
|
|
||||||
--all(-a) # Show all stopped containers (including those created by the run command)
|
|
||||||
--dry-run # Execute command in dry run mode
|
|
||||||
--filter: string # Filter services by a property (supported filters: status)
|
|
||||||
--format: string # Format output using a custom template: 'table': Print output in table; format with column headers (default) 'table TEMPLATE': Print output in table; format using the given Go template 'json': Print in JSON format; 'TEMPLATE': Print output using the given Go template; Refer to https://docs.docker.com/go/formatting/ for more information about formatting output with templates (default "table")
|
|
||||||
--no-truncate # Don't truncate output
|
|
||||||
--orphans # Include orphaned services (not declared by project) (default true)
|
|
||||||
--quite(-q) # Only display IDs
|
|
||||||
--services # Display services
|
|
||||||
--status: string@"nu-complete docker compose service status" # Filter services by status. Values: [paused | restarting | removing | running | dead | created | exited]
|
|
||||||
]
|
|
||||||
|
|
||||||
# Stop containers
|
|
||||||
export extern "compose stop" [
|
|
||||||
--dry-run # Execute command in dry run mode
|
|
||||||
--timeout(-t): int # Specify a shutdown timeout in seconds
|
|
||||||
]
|
|
||||||
|
|
||||||
# Restart service containers
|
|
||||||
export extern "compose restart" [
|
|
||||||
--dry-run # Execute command in dry run mode
|
|
||||||
--no-deps # Don't restart dependent services
|
|
||||||
--timeout(-t): int # Specify a shutdown timeout in seconds
|
|
||||||
]
|
|
||||||
|
|
||||||
# Create and start containers
|
|
||||||
export extern "compose up" [
|
|
||||||
--abort-on-container-exit # Stops all containers if any container was stopped. Incompatible with -d/--detach
|
|
||||||
--abort-on-container-failure # Stops all containers if any container had a non-zero exit code. Incompatible with -d/--detach
|
|
||||||
--always-recreate-deps # Recreate dependent containers. Incompatible with --no-recreate
|
|
||||||
--attach: string # Restrict attaching to the specified services. Incompatible with --attach-dependencies
|
|
||||||
--attach-dependencies # Automatically attach to log output of all dependent services
|
|
||||||
--build # Build images before starting containers
|
|
||||||
--detach(-d) # Detached mode: Run containers in the background
|
|
||||||
--dry-run # Execute command in dry run mode
|
|
||||||
--exit-code-from: string # Return the exit code of the selected service container. Implies --abort-on-container-exit
|
|
||||||
--force-recreate # Recreate containers even if their configuration and image haven't changed
|
|
||||||
--menu # Enable interactive shortcuts when running attached. Incompatible with --detach. Can also be enable/disable
|
|
||||||
--no-attach: string # Do not attach (stream logs) to the specified services
|
|
||||||
--no-build # Don't build an image, even if it's policy
|
|
||||||
--no-color # Produce monochrome output
|
|
||||||
--no-deps # Don't start linked services
|
|
||||||
--no-log-prefix # Don't print prefix in logs
|
|
||||||
--no-recreate # If containers already exist, don't recreate them. Incompatible with --force-recreate
|
|
||||||
--no-start # Don't start the services after creating them
|
|
||||||
--pull: string@"nu-complete docker pull" # Pull image before running ("always"|"missing"|"never") (default "policy")
|
|
||||||
--quite-pull # Pull without printing progress information
|
|
||||||
--remove-orphans # Remove containers for services not defined in the Compose file
|
|
||||||
--renew-anon-volumes(-V) # Recreate anonymous volumes instead of retrieving data from the previous containers
|
|
||||||
# --scale: scale # Scale SERVICE to NUM instances. Overrides the scale setting in the Compose file if present
|
|
||||||
--timeout(-t): int # Use this timeout in seconds for container shutdown when attached or when containers are already running
|
|
||||||
--timestamps # Show timestamps
|
|
||||||
--wait # Wait for services to be running|healthy. Implies detached mode
|
|
||||||
--wait-timeout: int # Maximum duration to wait for the project to be running|healthy
|
|
||||||
--watch(-w) # Watch source code and rebuild|refresh containers when files are updated
|
|
||||||
]
|
|
||||||
|
|
||||||
# An open-source container management platform.
|
|
||||||
export extern main [
|
|
||||||
--config: string # Location of client config files (default "/root/.docker")
|
|
||||||
--context(-c): string # Name of the context to use to connect to the daemon (overrides DOCKER_HOST env var and default context set with "docker context use")
|
|
||||||
--debug(-D) # Enable debug mode
|
|
||||||
--host(-H): string # Daemon socket(s) to connect to
|
|
||||||
--log-level(-l): string # Set the logging level ("debug"|"info"|"warn"|"error"|"fatal")
|
|
||||||
--tls # Use TLS; implied by --tlsverify
|
|
||||||
--tlscacert: string # Trust certs signed only by this CA
|
|
||||||
--tlscert: string # Path to TLS certificate file
|
|
||||||
--tlskey: string # Path to TLS key file
|
|
||||||
--tlsverify # Use TLS and verify the remote
|
|
||||||
--version(-v) # Print version information and quit
|
|
||||||
]
|
|
||||||
|
|
||||||
# Attach local standard input, output, and error streams to a running container
|
|
||||||
export alias "docker attach" = docker container attach
|
|
||||||
# Create a new image from a container's changes
|
|
||||||
export alias "docker commit" = docker container commit
|
|
||||||
export alias "docker cp" = docker container cp
|
|
||||||
# Create a new container
|
|
||||||
export alias "docker create" = docker container create
|
|
||||||
# Inspect changes to files or directories on a container's filesystem
|
|
||||||
export alias "docker diff" = docker container diff
|
|
||||||
# Execute a command in a running container
|
|
||||||
export alias "docker exec" = docker container exec
|
|
||||||
# Export a container's filesystem as a tar archive
|
|
||||||
export alias "docker export" = docker container export
|
|
||||||
# Display detailed information on one or more containers
|
|
||||||
export alias "docker inspect" = docker container inspect
|
|
||||||
# Kill one or more running containers
|
|
||||||
export alias "docker kill" = docker container kill
|
|
||||||
# Fetch the logs of a container
|
|
||||||
export alias "docker logs" = docker container logs
|
|
||||||
# Pause all processes within one or more containers
|
|
||||||
export alias "docker pause" = docker container pause
|
|
||||||
# List port mappings or a specific mapping for the container
|
|
||||||
export alias "docker port" = docker container port
|
|
||||||
# Rename a container
|
|
||||||
export alias "docker rename" = docker container rename
|
|
||||||
# Restart one or more containers
|
|
||||||
export alias "docker restart" = docker container restart
|
|
||||||
# List containers
|
|
||||||
export alias "docker ps" = docker container ls
|
|
||||||
# Remove one or more containers
|
|
||||||
export alias "docker rm" = docker container rm
|
|
||||||
# Run a command in a new container
|
|
||||||
export alias "docker run" = docker container run
|
|
||||||
# Start one or more stopped containers
|
|
||||||
export alias "docker start" = docker container start
|
|
||||||
# Display a live stream of container(s) resource usage statistics
|
|
||||||
export alias "docker stats" = docker container stats
|
|
||||||
# Stop one or more running containers
|
|
||||||
export alias "docker stop" = docker container stop
|
|
||||||
# Display the running processes of a container
|
|
||||||
export alias "docker top" = docker container top
|
|
||||||
# Unpause all processes within one or more containers
|
|
||||||
export alias "docker unpause" = docker container unpause
|
|
||||||
# Update configuration of one or more containers
|
|
||||||
export alias "docker update" = docker container update
|
|
||||||
# Block until one or more containers stop, then print their exit codes
|
|
||||||
export alias "docker wait" = docker container wait
|
|
||||||
|
|
||||||
# Build an image from a Dockerfile
|
|
||||||
export alias "docker build" = docker image build
|
|
||||||
# Show the history of an image
|
|
||||||
export alias "docker history" = docker image history
|
|
||||||
# Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
|
|
||||||
export alias "docker tag" = docker image tag
|
|
||||||
# List images
|
|
||||||
export alias "docker images" = docker image ls
|
|
||||||
# Remove one or more images
|
|
||||||
export alias "docker rmi" = docker image rm
|
|
||||||
# Download an image from a registry
|
|
||||||
export alias "docker pull" = docker image pull
|
|
||||||
# Upload an image to a registry
|
|
||||||
export alias "docker push" = docker image push
|
|
||||||
# Save one or more images to a tar archive (streamed to STDOUT by default)
|
|
||||||
export alias "docker save" = docker image save
|
|
||||||
|
|
||||||
# Inspect changes to files or directories on a container's filesystem
|
|
||||||
export alias "docker events" = docker system events
|
|
@ -0,0 +1,38 @@
|
|||||||
|
# authour: DWTW
|
||||||
|
|
||||||
|
def commandsGlow [] {
|
||||||
|
[ "config", "help", "stash" ]
|
||||||
|
}
|
||||||
|
|
||||||
|
# Render markdown on the CLI, with pizzazz!
|
||||||
|
export extern "glow" [
|
||||||
|
string?
|
||||||
|
--all(-a) # Show system files and directories (TUI)
|
||||||
|
--config: string # Specify config file
|
||||||
|
--help(-h) # Help for glow
|
||||||
|
--local(-l) # Show local files only
|
||||||
|
--pager(-p) # Display with pager
|
||||||
|
--style(-s): string # Style name or JSON path
|
||||||
|
--width(-w): int # Word-wrap width
|
||||||
|
]
|
||||||
|
|
||||||
|
# Create a config file
|
||||||
|
export extern "glow config" [
|
||||||
|
--help(-h) # Help for config
|
||||||
|
--config: string # Specify config file
|
||||||
|
]
|
||||||
|
|
||||||
|
# Provides help for any command
|
||||||
|
export extern "glow help" [
|
||||||
|
string?: string@commandsGlow
|
||||||
|
--help(-h) # Help for config
|
||||||
|
--config: string # Specify config file
|
||||||
|
]
|
||||||
|
|
||||||
|
# Do stash stuff
|
||||||
|
export extern "glow stash" [
|
||||||
|
string?
|
||||||
|
--memo: string # Memo or note for stashing
|
||||||
|
--help(-h) # Help for config
|
||||||
|
--config: string # Specify config file
|
||||||
|
]
|
@ -0,0 +1,64 @@
|
|||||||
|
def "nu-complete make" [] {
|
||||||
|
ls
|
||||||
|
| find --ignore-case makefile
|
||||||
|
| open $in.0.name
|
||||||
|
| lines
|
||||||
|
| find --regex '^[\w\.-]+\s*:'
|
||||||
|
| where ($it | str starts-with '.') == false
|
||||||
|
| split column ':' target
|
||||||
|
| get target
|
||||||
|
| str trim
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete make jobs" [] {
|
||||||
|
seq 1 (sys cpu | length)
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete make files" [] {
|
||||||
|
ls **/* | where type == file | get name
|
||||||
|
}
|
||||||
|
|
||||||
|
def "nu-complete make dirs" [] {
|
||||||
|
ls **/* | where type == dir | get name
|
||||||
|
}
|
||||||
|
|
||||||
|
export extern "make" [
|
||||||
|
command?: string@"nu-complete make"
|
||||||
|
--always-make(-B) # Unconditionally make all targets.
|
||||||
|
--directory(-C): string@"nu-complete make dirs" # Change to DIRECTORY before doing anything.
|
||||||
|
--debug(-d) # Print various types of debugging information.
|
||||||
|
--environment-overrides(-e) # Environment variables override makefiles.
|
||||||
|
--eval(-E): string # Evaluate STRING as a makefile statement.
|
||||||
|
--file(-f) # Read FILE as a makefile.
|
||||||
|
--help(-h) # Print this message and exit.
|
||||||
|
--ignore-errors(-i) # Ignore errors from recipes.
|
||||||
|
--include-dir(-I): string@"nu-complete make dirs" # Search DIRECTORY for included makefiles.
|
||||||
|
--jobs(-j): int@"nu-complete make jobs" # Allow N jobs at once; infinite jobs with no arg.
|
||||||
|
--keep-going(-k) # Keep going when some targets can't be made.
|
||||||
|
--load-average(-l): int@"nu-complete make jobs" # Don't start multiple jobs unless load is below N.
|
||||||
|
--check-symlink-times(-L) # Use the latest mtime between symlinks and target.
|
||||||
|
--just-print(-n) # Don't actually run any recipe; just print them.
|
||||||
|
--dry-run
|
||||||
|
--recon
|
||||||
|
--assume-old: string@"nu-complete make files" # Consider FILE to be very old and don't remake it.
|
||||||
|
--old-file(-o): string@"nu-complete make files"
|
||||||
|
--output-sync(-O) # Synchronize output of parallel jobs by TYPE.
|
||||||
|
--print-data-base(-p) # Print make's internal database.
|
||||||
|
--question(-q) # Run no recipe; exit status says if up to date.
|
||||||
|
--no-builtin-rules(-r) # Disable the built-in implicit rules.
|
||||||
|
--no-builtin-variables(-R) # Disable the built-in variable settings.
|
||||||
|
--silent(-s) # Don't echo recipes.
|
||||||
|
--quiet
|
||||||
|
--no-silent # Echo recipes (disable --silent mode).
|
||||||
|
--stop(-S) # Turns off -k.
|
||||||
|
--no-keep-going
|
||||||
|
--touch(-t) # Touch targets instead of remaking them.
|
||||||
|
--trace # Print tracing information.
|
||||||
|
--version(-v) # Print the version number of make and exit.
|
||||||
|
--print-directory(-w) # Print the current directory.
|
||||||
|
--no-print-directory # Turn off -w, even if it was turned on implicitly.
|
||||||
|
--what-if(-W): string@"nu-complete make files" # Consider FILE to be infinitely new.
|
||||||
|
--new-file: string@"nu-complete make files"
|
||||||
|
--assume-new: string@"nu-complete make files"
|
||||||
|
--warn-undefined-variables # Warn when an undefined variable is referenced.
|
||||||
|
]
|
@ -1,3 +1,7 @@
|
|||||||
export module bat.nu
|
export use bat-completions.nu *
|
||||||
export module docker.nu
|
export use curl-completions.nu *
|
||||||
export module git.nu
|
export use docker-completions.nu *
|
||||||
|
export use git-completions.nu *
|
||||||
|
export use glow-completions.nu *
|
||||||
|
export use make-completions.nu *
|
||||||
|
export use npm-completions.nu *
|
||||||
|
@ -0,0 +1,28 @@
|
|||||||
|
def "nu-complete npm" [] {
|
||||||
|
^npm -l
|
||||||
|
|lines
|
||||||
|
|find 'Run "'
|
||||||
|
|str trim
|
||||||
|
|split column -c ' '
|
||||||
|
|get column4
|
||||||
|
|str replace '"' ''
|
||||||
|
}
|
||||||
|
|
||||||
|
export extern "npm" [
|
||||||
|
command?: string@"nu-complete npm"
|
||||||
|
]
|
||||||
|
|
||||||
|
def "nu-complete npm run" [] {
|
||||||
|
open ./package.json
|
||||||
|
|get scripts
|
||||||
|
|columns
|
||||||
|
}
|
||||||
|
|
||||||
|
export extern "npm run" [
|
||||||
|
command?: string@"nu-complete npm run"
|
||||||
|
--workspace(-w)
|
||||||
|
--include-workspace-root
|
||||||
|
--if-present
|
||||||
|
--ignore-scripts
|
||||||
|
--script-shell
|
||||||
|
]
|
Loading…
Reference in New Issue