The quickest way to edit the hosts file is by typing. This is where you will have to edit the hosts file that records the domain name and the pointed IP address. You may find that you need to create a new VirtualHost with a new domain name. Windows users can use the mklink /d command. To create a Symlink from your /Dropbox to the /Sites folder, run: My personal favorite of Symlink utilization is to synchronize folders from /Dropbox to my /Sites folder, which is where I put all my web development files. Symbolic Link or Symlink works like a shortcut folder, but the system will treat it as if it is an actual folder. txt folder in TextEdit, which is the default app in OS X to edit plain text file. This command below will open the folder Desktop in Finder. The open command will open files of folders in the default app. You can run ls command in Ubuntu and OS X, but not in Windows. The ls command, however, will only work in a UNIX shell. Specifying a folder name ahead of the ls command will list the content of the folder specified, for example:įurthermore, you can also retrieve the details of the listed content such as the directory date (created), directory permission, and the directory owners. With this command, you can list the content of a directory. This is one of the commands that I personally use often, List Directory or known as ls. If you are running on Windows, use the copy command instead. Below is an example where we copy index.html and name the new file to about.html. Type cp command or copy, if you want to copy a file or folder. This example below will rename the index.html into about.html. You can also make use of the mv command to rename files and folders. This example below moves the style.css to a folder named /css. Use the mv command to move a particular file to a folder. You can specify more filenames, as follows, to create multiple files at once. Use the touch command to create an empty file. The mkdir command is compatible both in Terminal and Command Prompt. This example below will create three directories named foo, hello, and world all together at once. We can also create multiple folders at once. The following command, for example, will create a new directory named foo. This command creates a new directory with the specified name. To head back to the previous directory or go one level up of the current directory, type:Īnother command that you may find in need often is mkdir. You can navigate directly to the sub-directory of foo, like so: You can see below, the current directory is shown before the blinking cursor. Say you want to go to a folder named foo, you type: Terminal and Command Prompts both use the same cd command to change your current directory to the destination specified within the command. Often you will have to navigate through directories. Now, it’s time for you to rub your hands in glee and begin. So, for Windows users, I would suggest you to use Cygwin, UnxUtils, or Windows Services for UNIX Version 3.5 which brings some UNIX utilities to Windows. Note that some useful command lines may not be found in Windows. Everything is done on the keyboard and therefore keyboard shortcuts are your new best friends. This means no searching or highlighting text with the cursor. The second thing to know is that you won’t be able to use the mouse to move the cursor within Terminal or Command Prompt. Once you make a change to it, the change is not reversible so whatever you do with these two apps, should be done with caution (and preferably if you know what exactly you are getting yourself into). Both are powerful apps that give you access to the core of the OS you are on. We need to talk about Terminal and Command Prompt. Recommended Reading: Basic Shell Commands For Bloggers But First… If you aren’t a fan of typing commands, this post will start you off with just a few basic command lines to help you familiarize yourself with them. Yet, tools like Yeoman, Bower, and Google Web Starter Kit operate through command lines. Terminal and Command Prompt may not be the most convenient tool to use, particular for web designers, which is quite understandable, since web designers may be more familiar with graphical interfaces. We use them to tell the computer to perform specific tasks, usually by typing specific commands from Terminal and Command Prompt. You may have come across instructions in web design and development tutorials that tell you to do things like npm install or git clone, etc.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |