Search results
From wikinotes
- Netstat (category Pages using deprecated source tags)netstat shows TCP ports and their TCP-state. netstat -an # display netwk connections (listening, connected, etc) netstat -4 -f inet -n -r # display routing263 bytes (25 words) - 16:39, 3 July 2020
- Zsh antigen (category Pages using deprecated source tags)manager for zsh. pacaur -S antigen Plugins are declared within your ~/.zshrc. source /path/to/antigen.zsh antigen bundle zsh-users/zsh-autosuggestions antigen562 bytes (33 words) - 17:23, 8 November 2020
- Ruby irb (category Pages using deprecated source tags)ruby-irb # ~/.irbrc IRB.conf[:USE_SINGLELINE] = true # use 'readline' instead of multiline support irb irb --readline # uses readline, but disables multiline672 bytes (40 words) - 22:02, 17 May 2023
- Pftop (category Pages using deprecated source tags)tool like top, that monitors traffic through pf firewall. 1 # 2 # 3 # 4 # 5 # packets blocked for each rule f # filter (see below) filter syntax is very732 bytes (72 words) - 17:02, 1 July 2021
- Python setup.cfg (category Pages using deprecated source tags)Consolidates some python project dotfiles. Mostly superceeded by python pyproject.toml. [tool:pytest] python_files = *.py testpaths = tests norecursedirs737 bytes (21 words) - 15:07, 13 February 2021
- Readline (category Pages using deprecated source tags)Reads line from a terminal, executes them. Can be configured to use vi keybindings. set editing-mode vi set keymap vi # meta+(hjkl) jumps into normal mode869 bytes (90 words) - 23:14, 18 June 2020
- FreeBSD ifconfig (category Pages using deprecated source tags)FreeBSD uses ifconfig to manage network interfaces. manipulate interfaces within shell. # create/destroy a network interface of type 'tun' ifconfig tun1 KB (66 words) - 03:36, 7 August 2021
- Vim cli (category Pages using deprecated source tags)vim -p a b c # open in new tabs vim -o a b c # open in vert splits vim -O a b c # open in horiz splits vim --cmd "let foo=bar" --cmd "let bar=baz" # run824 bytes (92 words) - 18:38, 8 April 2023
- Php anatomy (category Pages using deprecated source tags)<?php class Automobile { def drive() { } }80 bytes (5 words) - 00:47, 9 July 2020
- Php comments (category Pages using deprecated source tags)/** Do something * * @param $name * @return string */ function get_hello_message($name) { // comment /* foo bar baz */ }180 bytes (15 words) - 01:21, 9 July 2020
- Gsudo (category Pages using deprecated source tags)sudo for windows! choco install -y gsudo271 bytes (7 words) - 02:08, 4 January 2021
- NvimPlugin: telescope (category Pages using deprecated source tags)Extendable search. Can be powered by fzf. :Telescope lsp_workspace_symbols query=Foo::Bar::Baz125 bytes (15 words) - 23:35, 23 February 2024
- Iftop (category Pages using deprecated source tags)S # display source port D # display destination port n # show IP instead of host name P # pause ? # display additional commands TX: transmitted RX: received360 bytes (24 words) - 21:34, 1 June 2018
- Gnu ps (category Pages using deprecated source tags)# show the environment for a PID at the time the process was started ps -xep ${PID}115 bytes (16 words) - 01:59, 1 September 2023
- Php print (category Pages using deprecated source tags)echo "some text\n"; pring "some text\n"; $animals = array("cat", "dog", "monkey"); print_r($animals);132 bytes (16 words) - 12:31, 9 July 2020
- Vim profiling (category Pages using deprecated source tags):profile start profile.log :profile func * :profile file * " At this point do slow actions :profile pause :noautocmd qall!152 bytes (18 words) - 00:26, 10 February 2024
- Linux ip (category Pages using deprecated source tags)The linux ip command is used to manage network interfaces on linux. ip addr # list network interfaces ip set wlp3s0 up # activate network interface203 bytes (24 words) - 20:02, 1 July 2020
- Linux iw (category Pages using deprecated source tags)iw is used to manage wireless internet connections from linux. iw wlp3s0 info # print wireless connection info iw wlp3s0 scan # scan for access points198 bytes (24 words) - 21:45, 1 July 2020
- Df (category Pages using deprecated source tags)df lists volume information, how much room is consumed, remaining, etc. df -h # print consumption, in human readable sizes206 bytes (19 words) - 13:49, 20 September 2020
- File (category Pages using deprecated source tags)file gives you information about the type of file. sudo file -s -L /dev/sdc1199 bytes (15 words) - 11:49, 9 June 2020
- Lsof (category Pages using deprecated source tags)lsof prints files that are currently open. lsof # list files belonging to active processes395 bytes (14 words) - 13:46, 20 September 2020
- Ntfs (category Pages using deprecated source tags)maximum characters Windows restricts paths to a max of 260 characters (with their bytestring path interface, unicode supports longer paths) Invalid filenames638 bytes (50 words) - 19:27, 12 February 2022
- Php composer (category Pages using deprecated source tags)dependency manager for php. brew install composer # [MacOS] not in macports cd project/ # dir with composer.json composer install # install deps322 bytes (21 words) - 13:35, 8 July 2020
- Host (category Pages using deprecated source tags)google.com # DNS query for google.com host google.com 8.8.8.8 # DNS query using 8.8.8.8 as nameserver271 bytes (35 words) - 01:09, 7 August 2021
- Coc-graphql (category Pages using deprecated source tags)" requirement Plug 'https://github.com/jparise/vim-graphql' :CocInstall coc-graphql Add a graphql-config to your project # ${project}/.graphqlrc # See:629 bytes (38 words) - 03:56, 11 February 2021
- Php exceptions (category Pages using deprecated source tags)throw new Exception("Division by zero"); try { // code that can throw exceptions } catch(Exception $e) { // code that runs when an exception is caught430 bytes (35 words) - 01:15, 9 July 2020
- Google chrome (category Pages using deprecated source tags)Settings > Keyboard: Shortcuts: App Shortcuts: - (All Applications) Close Tab: Ctrl+W # create - (Google Chrome) Select Next Tab: Ctrl+P # create - (Google586 bytes (28 words) - 00:04, 10 February 2024
- Python conditionals (category Pages using deprecated source tags)if var == 'no' : print "something" elif var == 'yes' : print "something else" else: print "something else entirely" You may find the all keyword useful:532 bytes (46 words) - 02:01, 14 February 2024
- Windows filesystem permissions (category Pages using deprecated source tags)TODO: I definitely have detailed notes on this somewhere.. TODO: Also record standardized locations with friendly permisisons (like for ssh keys) msg /server:wintermute436 bytes (49 words) - 22:59, 18 April 2021
- Ruby chruby (category Pages using deprecated source tags)rbenv. Consider using nix and direnv instead. cd yourproject/ echo "2.6.5" > .ruby-version # now when you enter directory, correct ruby is used automatically294 bytes (32 words) - 20:10, 14 August 2020
- Ruby rails: dates and times (category Pages using deprecated source tags)tzinfo = ActiveSupport::TimeZone.find_tzinfo("America/Toronto") timezone = ActiveSupport::TimeZone.new(tzinfo) Time.parse("1970-01-01T10:00:00Z").in_timezone(timezone)258 bytes (22 words) - 16:08, 7 February 2024
- Dtrace (category Pages using deprecated source tags)Watch/Count syscalls that a process makes. # dtrace is included in base system pkg install dtrace-toolkit # (optional) dtrace scripts kldload dtraceall927 bytes (44 words) - 19:48, 13 September 2020
- Freebsd vt (category Pages using deprecated source tags)Console Driver (tty) for FreeBSD, introduced as default in FreeBSD-12. # /boot/loader.conf vt.kern.vty = "sc" # enable syscons590 bytes (20 words) - 01:39, 8 February 2021
- Mycli (category Pages using deprecated source tags)mycli is an alternative mysql/mariadb/percona client built overtop of prompt_toolkit. pacaur -S mycli pip install mycli [main] multi_line = True key_bindings811 bytes (31 words) - 23:28, 17 December 2020
- Nmap (category Pages using deprecated source tags)nmap is a commandline port scanner. # don't use sudo. give your user permission to X nmap -sP '192.168.1.*' # scan all ips in addr range nmap 192.168.1637 bytes (59 words) - 01:01, 1 October 2020
- Bind-tools (category Pages using deprecated source tags)NOTE: see also dig # get BGP protocol ASN for facebook whois -h v4.whois.cymru.com " -v $(host facebook.com | grep "has address" | cut -d " " -f4)" | tail515 bytes (76 words) - 21:29, 11 October 2021
- Vim shell (category Pages using deprecated source tags)the commandline from vim's command mode. :w !sh " execute the current file using /bin/sh :w !less " pipe entire file to less :'<,'>!less " pipe visual-selection566 bytes (62 words) - 15:51, 10 February 2024
- Php fpm (category Pages using deprecated source tags)PHP fastcgi process manager. Can be configured to listen on a port or socket. Configure where php-fpm should listen # /usr/local/etc/php-fpm.d/www.conf766 bytes (82 words) - 18:33, 4 April 2021
- Coc-python (category Pages using deprecated source tags)NOTE: unmaintained, use coc-pyright instead python -m pip install jedi python -m pip install pylint :CocInstall coc-python " Interactive Choice :CocCommand927 bytes (41 words) - 00:43, 27 December 2021
- Ifuse (category Pages using deprecated source tags)interact with ios device filesystem on computer. sudo pacman -S libimobiledevice ifuse # unlock phone, plug into computer, and on iphone # 'trust' the817 bytes (74 words) - 19:52, 21 February 2021
- Ruby syntaxtree (category Pages using deprecated source tags)a very fast ruby ast node-types all defined within node.rb stree match /some/file.rb # generate matcher code stree search 'VarRef' /some/file.rb # search734 bytes (49 words) - 00:25, 1 February 2024
- Javascript debuggers (category Pages using deprecated source tags)commands to jump for next/step/continue like gdb. instead you have to use the UI, or use OS-specific hotkeys: super ' # next super ; # step super \ # continue737 bytes (64 words) - 20:42, 22 February 2024
- Vimdiff (category Pages using deprecated source tags)]c - advance to the next block with differences [c - reverse search for the previous block with differences do (diff obtain) - bring changes from the other847 bytes (104 words) - 21:12, 26 January 2021
- Zfs zdb (category Pages using deprecated source tags)man zdb https://www.unix.com/man-page/FreeBSD/8/zdb/901 bytes (70 words) - 01:11, 18 November 2020
- Korganizer (category Pages using deprecated source tags)-latest.exe It is very much a work in progress, at this stage you cannot use calendars at all. Settings > Configure Korganizer General > Calendars > Add1 KB (103 words) - 22:19, 8 February 2021
- Bat (category Pages using deprecated source tags)Bat is a syntax highlighted cat. bat file.graphql bat \ -l go `# syntaxhighlight for lang` \ --file-name 'my-file.go' `# set file title in result` \ --theme1 KB (72 words) - 21:54, 6 May 2023
- Ruby operators (category Pages using deprecated source tags)and or 1 == 1 1 != 0 1 <= 2 2 >= 1 'foo' =~ 'foobar' # 'foobar' contains 'foo' a ||= b # `a || a = b` (if a is not defined, a = b) obj_1 eql? obj_2 # if748 bytes (93 words) - 21:39, 17 April 2020
- Ruby iruby (category Pages using deprecated source tags)ruby. NOTE: It does not appear that iruby supports vi editing mode. I would use ruby pry instead, it has 1st-tier support. sudo pacman -S libffi libtool ruby516 bytes (50 words) - 15:15, 10 April 2020
- Ruby rubocop-ast (category Pages using deprecated source tags)nodes https://github.com/rubocop/rubocop-ast/blob/master/docs/modules/ROOT/pages/node_types.adoc Node Patterns (like AST selectors) https://docs.rubocop.938 bytes (58 words) - 00:22, 1 February 2024
- Coreutils dd (category Pages using deprecated source tags)on FreeBSD, you'll need to create a virtual block device # for the image using: # mdconfig -a -t vnode -f /path/to/image.img -u 0 # link image to virtual687 bytes (96 words) - 19:26, 28 March 2021
- Bottom (category Pages using deprecated source tags)Configurable/Cross-Platform commandline resource manager written in rust. Similar to gnu top. Has a vi mode. NOTE: neat, but graphs are CPU drains and903 bytes (55 words) - 13:56, 24 January 2021
- Xchm (category Pages using deprecated source tags)xchm file.chm44 bytes (3 words) - 23:06, 8 October 2018
- Kchmviewer (category Pages using deprecated source tags)kchmviewer file.chm50 bytes (3 words) - 23:06, 8 October 2018
- Xarchiver (category Pages using deprecated source tags)xarchiver is a GUI program to manage various archive formats sudo pacman -S xarchiver117 bytes (14 words) - 14:54, 25 May 2019
- Osascript (category Pages using deprecated source tags)Applescript osascript -e 'display notification "nice text" with title "nice title"'133 bytes (11 words) - 16:13, 8 August 2020
- Wipe (category Pages using deprecated source tags)Deletes files within a filesystem. I haven't had the occasion to use it yet. wipe -r /path/to/wipe130 bytes (19 words) - 19:43, 3 August 2019
- Cbsd install (category Pages using deprecated source tags)pkg install cbsd47 bytes (3 words) - 20:44, 7 June 2020
- Latex comments (category Pages using deprecated source tags)% a comment43 bytes (2 words) - 15:13, 10 July 2021
- Aria2 (category Pages using deprecated source tags)sudo pacman -S aria2 aria2c file.torrent # start a torrent download224 bytes (11 words) - 16:27, 11 July 2019
- Elisp math (category Pages using deprecated source tags)(+ 3 4) ;; adds 3 and 455 bytes (6 words) - 18:54, 11 January 2020
- Elisp comments (category Pages using deprecated source tags);; comments begin with double-semicolons71 bytes (5 words) - 18:34, 11 January 2020
- Nix conditionals (category Pages using deprecated source tags)if true then "true" else "false"62 bytes (6 words) - 01:00, 16 August 2020
- Google docs (category Pages using deprecated source tags)Tools --> Preferences --> Automatically detect Markdown87 bytes (5 words) - 13:33, 6 April 2023
- Icsharp (category Pages using deprecated source tags)NOTE: Did not work for me sudo pacman -S mono git clone https://github.com/zabirauf/icsharp cd icsharp xbuild202 bytes (20 words) - 21:06, 2 November 2019
- Javascript comments (category Pages using deprecated source tags)/* Multiline * comment */ let foo = 1 // comment90 bytes (6 words) - 17:42, 23 May 2021
- Ruby comments (category Pages using deprecated source tags)# line comment63 bytes (2 words) - 20:14, 5 December 2019
- Notify-send (category Pages using deprecated source tags)Issue a notification from the commandline on a linux/bsd server. notify-send SUMMARY BODY121 bytes (15 words) - 16:09, 8 August 2020
- Zip (category Pages using deprecated source tags)requests a password, encryption algorithm varies` verify encryption algorithm used 7z l -slt file.zip332 bytes (31 words) - 19:29, 13 August 2022
- Ruby json (category Pages using deprecated source tags)require 'json' {"a" => "b"}.to_json #> '{"a": "b"}' JSON.parse('{"a": 1}') #> { "a" => 1 }124 bytes (14 words) - 20:18, 6 November 2020
- Vbscript functions (category Pages using deprecated source tags)Sub mysub(argument1,argument2) some statements End Sub86 bytes (8 words) - 00:18, 8 December 2019
- Powershell datetime (category Pages using deprecated source tags)Get-Date Get-TimeZone Set-TimeZone 'Eastern Standard Time'95 bytes (9 words) - 13:38, 9 August 2019
- Qutebrowser install (category Pages using deprecated source tags)sudo pacman -S qutebrowser # archlinux choco install -y qutebrowser # windows brew cask install qutebrowser # macos153 bytes (15 words) - 17:12, 15 May 2021
- Unrar (category Pages using deprecated source tags)Compress/Extract rar archives. # extract, preserving directory structure unrar x src.rar /path/out/182 bytes (14 words) - 03:18, 2 July 2022
- Coreutils chown (category Pages using deprecated source tags)Change the user/group that owns a file. chown user:group file121 bytes (11 words) - 19:25, 28 March 2021
- Pulseaudio install (category Pages using deprecated source tags)sudo pacman -S pulseaudio pulseaudio-alsa sudo pacman -S pavucontrol-qt102 bytes (11 words) - 00:33, 26 March 2021
- Java logging (category Pages using deprecated source tags)TODO: UNFINISHED! import java.util.logging.Logger; import java.util.logging.*;117 bytes (11 words) - 19:47, 2 November 2019
- Nullfs (category Pages using deprecated source tags)Mount directories as other directories. mount -t nullfs /mnt/mywebsite /usr/local/www/mywebsite178 bytes (14 words) - 18:47, 1 May 2021
- Powershell registry (category Pages using deprecated source tags)Set-ItemProperty -Path 'Registry::HKCU\Environment' -Name PATH -Value ($PATH.Path +";"+ $rezbin_PATH)138 bytes (13 words) - 12:22, 6 August 2019
- Bsd jot (category Pages using deprecated source tags)jot -r 1 1 50 # 1 random num between 1 and 5078 bytes (12 words) - 19:48, 28 March 2021
- Wireguard usage (category Pages using deprecated source tags)wg # print configured connections wg show # print configured connections wg-quick up wg0 # activate wg0158 bytes (15 words) - 03:14, 4 July 2020
- Viml comments (category Pages using deprecated source tags)Lines matching '\s*"' are comments. " a comment " another comment113 bytes (9 words) - 19:09, 10 May 2019
- Exfat (category Pages using deprecated source tags)FreeBSD # requires port: sysutils/fusefs-exfat # NOTE: I was unable to compile (2020/05) mount -t exfat /dev/ad1s1 /mnt273 bytes (20 words) - 21:02, 14 June 2020
- Launchd (category Pages using deprecated source tags)commandline launchctl -h353 bytes (3 words) - 23:51, 15 September 2021
- Gnu ls (category Pages using deprecated source tags)ls --group-directories-first ls -X # sort by file-extension ls -v # sort with natural sorting176 bytes (16 words) - 01:30, 25 May 2021
- Elisp print (category Pages using deprecated source tags)(message "her name is %s, her age is %d" (list "vickie" 24) ) ;; print with substitution (print "abc") ;; normal print199 bytes (19 words) - 18:38, 11 January 2020
- Yum (category Pages using deprecated source tags)CentOS uses a the rpm based package manager YUM. yum search <package> # search for a package yum install <package> # install package yum update # update305 bytes (37 words) - 14:04, 14 March 2021
- Nix operators (category Pages using deprecated source tags)Full list https://nixos.org/nix/manual/#sec-language-operators 1 + 1 # addition 1 - 1 # subtraction 1 * 1 # multiplication 1 / 1 # division175 bytes (22 words) - 02:20, 16 August 2020
- Rpcs3 (category Pages using deprecated source tags)RPCS3 is a playstation 3 emulator. pacaur -S cereal pacaur -S rpcs3-git158 bytes (13 words) - 16:51, 21 May 2018
- Vbscript variables (category Pages using deprecated source tags)Dim var ' Normal variable within scope Public var ' Global variable Private var ' (? private to what)154 bytes (15 words) - 00:09, 8 December 2019
- Powershell debugger (category Pages using deprecated source tags)Set-PSBreakpoint # set breakpoint on current line Set-PSBreakpoint -Line 15 # set breakpoint on line 15190 bytes (16 words) - 00:16, 26 November 2019
- Anbox (category Pages using deprecated source tags)Anbox is an android emulator for linux. pacman -S anbox142 bytes (10 words) - 02:30, 8 February 2021
- Ijava (category Pages using deprecated source tags)sudo pacman -S jupyter pacaur -S jre pacaur -S jdk11 git clone https://github.com/SpencerPark/IJava.git cd IJava/ sudo chmod u+w gradlew ./gradlew installKernel276 bytes (31 words) - 16:27, 8 June 2019
- Cmake operators (category Pages using deprecated source tags)IF( <expr> AND <expr> ) IF( <expr> OR <expr> ) https://cmake.org/cmake/help/v3.11/command/if.html130 bytes (18 words) - 18:58, 18 May 2018
- Powershell conditionals (category Pages using deprecated source tags)if ($PATH[0] -ne 'C:\Python27') { ... } # if statement if (!( $PATH.Contains('C:\Python27') )){ ... } # if not statement178 bytes (16 words) - 03:26, 19 September 2018
- Csv (category Pages using deprecated source tags)CSVs are comma separated tables. headers are available, but not mandatory. entries may include commas if the row/column is written within double-quotes356 bytes (43 words) - 16:53, 20 January 2021
- Dia (category Pages using deprecated source tags)A UML or general node-based diagram tool. sudo pacman -S dia106 bytes (12 words) - 00:06, 30 August 2018
- Ruby yaml (category Pages using deprecated source tags)require 'yaml' YAML.load("a: 1", aliases: true) #> {"a"=>1} YAML.dump(['a', ['b']], indentation: 2)132 bytes (16 words) - 20:46, 19 September 2022
- Python install (category Pages using deprecated source tags)pacman -S python # Archlinux pkg install python37 # FreeBSD brew install python # MacOS178 bytes (12 words) - 16:41, 10 July 2021
- Ini (category Pages using deprecated source tags)values can be put in sections sections cannot be nested '=' or ':' may be used interchangeably [section a] key_1 = value1 key_2 = value2 [section b] key_3276 bytes (40 words) - 13:17, 5 April 2019
- Python ctypes (category Pages using deprecated source tags)import ctypes #returns kernel ctypes.windll.kernel32110 bytes (7 words) - 20:45, 6 May 2018