Tuesday, July 30, 2013

Các lệnh về file

Xóa file và thư mục:
-Xóa file:

$ rm {name file}
$ rm -f {name file}:không hỏi lại có muốn xóa không?

-Xóa thư mục:
$ rm -rf {name folder}

Trong đó
-r : Attempt to remove the file hierarchy rooted in each file argument i.e. recursively remove subdirectories and files from the specified directory
-f : Attempt to remove the files without prompting for confirmation, regardless of the file's permissions

Related Posts:

  • ADD THÊM YUM REPOSITORY+Yum repository có cấu hình trong file /etc/yum.conf. Các file cấu hình bổ sung sẽ được đọc từ một thư mục khác, mặc định sẽ là /etc/yum.repos.d . Các bạn có thể list thư mục này ra xem nó có những repository nào.+Để sử dụng … Read More
  • Install PHP 5.4 and MySQL 5.5 in CentOS 6.4 via Yum How about default? For example, look at PHP version. CentOS $ yum info php Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: mirrors.sin3.sg.voxel.net * extras: mirrors.sin3.sg.voxel.net … Read More
  • Installing latest version of MySQL via yum Usually when you try to install MySQL via yum, by default, the version that comes with your OS is always an old version (not the latest version available frommysql.com/downloads).In order to have the latest version, you alwa… Read More
  • Compile php Get sources Go to PHP downloads, choose the version wanted and copy a link from a mirror you prefere. php-5.5.0 version will be used in current example. mkdir ~/compile && cd ~/compile wget http://lt1… Read More
  • Install phalcon with MAMP This is instructions on how to compile and install the phalcon extension on Mac OS X (Lion), along with command-line tools. Everything will be done through the terminal, except installation of Xcode and the comma… Read More