Page 2 of 5 FirstFirst 1234 ... LastLast
Results 11 to 20 of 42

Thread: how do people remember lots of commands..??

  1. #11
    Join Date
    Dec 2008
    Location
    Indiana, United States
    Beans
    734

    Re: how do people remember lots of commands..??

    xfce notes plugin for often used commands. most commands i use on a daily basis are easy to remember though. like cd,mv,cp etc.
    Whoever came up with the phrase "There is no such thing as a stupid question" obviously never had the internet.

  2. #12
    Join Date
    Apr 2011
    Location
    Maryland
    Beans
    1,461
    Distro
    Kubuntu 12.04 Precise Pangolin

    Re: how do people remember lots of commands..??

    To me, the best thing to remember is what is possible. If I know that something can be done with a command (usually because I learned a new one from somewhere), then I don't need to necessarily remember the exact syntax, unless it's very complicated. For example, I recently learned that you can do case-insensitive recursive searches with grep, and pass the output with a line number:

    Code:
    grep -rin <query> <location>

    Another good example is using bash history with a search and replace (for example if I mistyped something or need to make a small change to a long command:


    Code:
    !!:gs/<thing to be replaced>/<thing to replace it>/
    I've been using that a ton for a project that I've been working on that has a lot of files that pass variables around. So, I can use that to help me remember where the calls are being made and in which line of which script.

    Late on, if I forget that exact syntax, just that I know it's possible will make me do quick searches in the manpages or through Google to get the syntax correct.

    For longer one-liners that approach script length, but not enough to put a whole script together, I usually keep a txt document with those and what they do for quick reference.

    In short, I think just playing around a lot and trying things will lead you to find things that you didn't know you could do before. Then using this forum, the man pages, and Google to get the syntax exactly correct.

  3. #13
    Join Date
    Mar 2008
    Location
    Sussex, UK
    Beans
    1,326
    Distro
    Ubuntu

    Re: how do people remember lots of commands..??

    I find CLI Companion very useful "CLI Companion is a tool to store and run Terminal commands from a GUI. People unfamiliar with the Terminal will find CLI Companion a useful way to become acquainted with the Terminal and unlock its potential. Experienced users can use CLI Companion to store their extensive list of commands in a searchable list." Here: https://launchpad.net/clicompanion

  4. #14
    Join Date
    Jun 2009
    Location
    0:0:0:0:0:0:0:1
    Beans
    4,137
    Distro
    Xubuntu 13.04 Raring Ringtail

    Re: how do people remember lots of commands..??

    cat ~/.bash_history | grep "fragment of command"

    some things i make a script to run so i just type the script name to run some long command
    eg:
    Code:
    echo -e '#!/bin/sh\ncat ~/.bash_history | grep "$1"' | sudo tee /usr/local/bin/brain-fart;sudo chmod +x /usr/local/bin/brain-fart
    never knew about ctrl+r before now
    Last edited by pqwoerituytrueiwoq; November 5th, 2012 at 08:38 AM.
    Laptop: ASUS A54C-NB91 (Storage: WD3200BEKT + MKNSSDCR60GB-DX); Desktop: Custom Build - Images included; rPi Server
    Putting your Networked Printer's scanner software to shame PHP Scanner Server
    I frequently edit my post when I have the last post

  5. #15
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    8,835
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: how do people remember lots of commands..??

    The "apropos" command can sometimes help. It will list all the possible man pages that apply to the object of apropos. For instance, "apropos copy" brings up not only cp and scp, but also rsync and ssh-copy-id. Each item has a brief description; you can see the full documentation with the man command.

    Other than that, it's just a matter of experience. I've used the command line every day for years, so most commands are just second nature by now. If I want to do something that I cannot remember the command for, I either try apropos or do a Google search.
    If you ask for help, please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  6. #16
    Join Date
    Jul 2011
    Location
    /Europe/Netherlands
    Beans
    382
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: how do people remember lots of commands..??

    There are so many bash tricks I don't know. CTRL+R is a good one. Thanks!

    I also like the case insensitive history search. I have just put this in my ~/.bashrc:
    Code:
    hgrep() {history | grep -i $@ ;}
    "I believe humans get a lot done, not because we're smart, but because we have thumbs so we can make coffee." --Flash Rosenberg
    formerly 'known' as Euroman

  7. #17
    Join Date
    Dec 2010
    Beans
    940

    Re: how do people remember lots of commands..??

    Quote Originally Posted by MG&TL View Post
    I just tend to remember how to use stuff I use on a regular basis. Others I just look up.

    Bash's history is a lifesaver too, as is the Ctrl-R search.
    Bash's history is a lifesaver too, as is the Ctrl-R search.
    My life has been a lie.

  8. #18
    Join Date
    May 2010
    Location
    South Gloucestershire, UK
    Beans
    1,751
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: how do people remember lots of commands..??

    Quote Originally Posted by MG&TL View Post
    Bash's history is a lifesaver too, as is the Ctrl-R search.
    How come I've been here for two and a half years and never come across this very useful command?

    Thanks MG&TL, I shall be using that a lot.

  9. #19
    Join Date
    Jun 2008
    Location
    Mumbai
    Beans
    223
    Distro
    Ubuntu

    Re: how do people remember lots of commands..??

    i didn't know that ...thanks man

  10. #20
    Join Date
    Jun 2008
    Location
    Mumbai
    Beans
    223
    Distro
    Ubuntu

    Re: how do people remember lots of commands..??

    Thanks all for the valuable tricks and some tips ...

    A beer from me to all community cafe users

    cheers..=D>

Page 2 of 5 FirstFirst 1234 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •