mirror of
https://github.com/ivuorinen/dotfiles.git
synced 2026-02-15 12:53:38 +00:00
feat(config): fish configs
This commit is contained in:
19
config/fish/functions/__macos_mac_flushdns.fish
Normal file
19
config/fish/functions/__macos_mac_flushdns.fish
Normal file
@@ -0,0 +1,19 @@
|
||||
# @halostatue/fish-macos/functions/__macos_mac_flushdns.fish:v7.0.0
|
||||
|
||||
function __macos_mac_flushdns
|
||||
argparse --name 'mac flushdns' h/help -- $argv
|
||||
or return 1
|
||||
|
||||
if set --query _flag_help
|
||||
echo 'Usage: mac flushdns [options]
|
||||
|
||||
Flushes the DNS cache. Requires sudo.
|
||||
|
||||
Options:
|
||||
-h, --help Show this help'
|
||||
return 0
|
||||
end
|
||||
|
||||
sudo dscacheutil -flushcache
|
||||
and sudo killall -HUP mDNSResponder
|
||||
end
|
||||
Reference in New Issue
Block a user