About: Insert current directory name   Sponge Permalink

An Entity of Type : owl:Thing, within Data Space : 134.155.108.49:8890 associated with source dataset(s)

Move to a blank line, "V" to visually select it, then "!pwd" Basically you're using the filter command "!" to filter a null selection and replace it with the output of that command. "pwd" on Unix-like systems returns the current directory, so you can use it to grab the current directory name with "!pwd", listing of files with "!ls", etc. Another way is to use "CTRL-R = getcwd()". This is more typing but executes faster because it's not spawning an external command (the pwd command). If you do this a lot it's better to use inoremap to bind that sequence to a dedicated key.

AttributesValues
rdfs:label
  • Insert current directory name
rdfs:comment
  • Move to a blank line, "V" to visually select it, then "!pwd" Basically you're using the filter command "!" to filter a null selection and replace it with the output of that command. "pwd" on Unix-like systems returns the current directory, so you can use it to grab the current directory name with "!pwd", listing of files with "!ls", etc. Another way is to use "CTRL-R = getcwd()". This is more typing but executes faster because it's not spawning an external command (the pwd command). If you do this a lot it's better to use inoremap to bind that sequence to a dedicated key.
Version
  • 5(xsd:double)
dbkwik:vim/property/wikiPageUsesTemplate
Previous
  • 1321(xsd:integer)
Author
  • Robert
Complexity
  • basic
Created
  • 2006(xsd:integer)
ID
  • 1322(xsd:integer)
NEXT
  • 1323(xsd:integer)
Rating
  • -4(xsd:integer)
abstract
  • Move to a blank line, "V" to visually select it, then "!pwd" Basically you're using the filter command "!" to filter a null selection and replace it with the output of that command. "pwd" on Unix-like systems returns the current directory, so you can use it to grab the current directory name with "!pwd", listing of files with "!ls", etc. Another way is to use "CTRL-R = getcwd()". This is more typing but executes faster because it's not spawning an external command (the pwd command). If you do this a lot it's better to use inoremap to bind that sequence to a dedicated key. :inoremap \fp =getcwd() Then in insert mode, the key sequence backslash f p will insert the current working directory.
Alternative Linked Data Views: ODE     Raw Data in: CXML | CSV | RDF ( N-Triples N3/Turtle JSON XML ) | OData ( Atom JSON ) | Microdata ( JSON HTML) | JSON-LD    About   
This material is Open Knowledge   W3C Semantic Web Technology [RDF Data] Valid XHTML + RDFa
OpenLink Virtuoso version 07.20.3217, on Linux (x86_64-pc-linux-gnu), Standard Edition
Data on this page belongs to its respective rights holders.
Virtuoso Faceted Browser Copyright © 2009-2012 OpenLink Software