Search code examples
macosvimcopypwdpbcopy

Unable to pbcopy at Vim's ED editor


I have tried unsuccessfully to copy the pwd to pbcopy as follows

pwd | !pbcopy

How can you copy your path in Vim's ED editor (: -mode)?


Solution

  • Why not :!pwd|pbcopy?

    Use the command

    cd
    

    to the current working directory if needed with the command

    lcd %:p:h