Application->Accessories->Terminalspark@spark-desktop:~$~ means: /home/spark$ menas: normal users (# means root)hundreds of commands can be used in linux, only 10 to 20 command are usually used in everyday life.command:--help : option means
http://www.understudy.net/custom.html Descriptioncsh*kshbashtcsh*zshCurrent working directory$CWD$PWD\w%/%/Current working directory, with one's home directory by `~'$CWD:t$PWD##*/\W%~%~Full hostname'uname -n''uname -n'N/A%M%MHostname up to the
import java.util.Arrays;public class ShellSort { public static void shellSort(DataWraper[] data){ System.out.println("開始排序:"); int arrayLength=data.length; int h=1; //按h*3+1得到增量序列的最大值 while(h<arrayLength/3){
在shell中寫代碼,有些命令比較常用,所以整合到一起來實現一些小功能,筆記一下:第一個指令碼是用來對比SVN中的不同版本的不同,藉助了svn自身的命令列工具和vimdiff工具: 代碼Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->#!/bin/sh#filename=date +%Y%m%d%H%M%Sfilename=${1##*/}if [
有時自己寫點小工具自己用,比較喜歡非圖形介面的,可是有些應用還是彈出個東西來提醒一下,才能讓你注意。zenity是個很帥的東西,它用法可以參考它的--help ,這裡不多贅述了,下面是一個我的例子: 這個是用來查詢使用者在部落格園資訊的小東東,呵呵 。My Code中是用python來調用的shell命令出現圖形介面,其實pygtk更帥,正在學習中……(沒能上傳源碼包,只好粘這兒了,呵呵 )Code highlighting produced by Actipro
package com.things.boring.runtime;import java.io.BufferedReader;import java.io.IOException;import java.io.InputStream;import java.io.InputStreamReader;public class RuntimeTest { /** * Run a command in the command line just like the console.
控制語句常用的列出以下三種。小寫字串表示控制命令,大寫的表示其他意義。1. if TEST then COMMANDS elif TEST then COMMANDS fi2. for VAR in LIST do COMMANDS done3. while TEST do COMMANDS doneCOMMANDS,指命令的集合;VAR,指的是變數;TEST是測試語句,有幾種形式:View Code 1 [ -a FILE ] 如果 FILE 存在則為真。 2 [ -
whoall users currently logged in to the systemcatexamine the contents of a filewc -l wc -wwc -cget a count of the total number of lines, words, and characters of information contained in a file cutcut -cchars file$ who root console Feb 24
by Vivek Gite on October 16, 2007 · 23 commentsQ. I'm new to Linux and installed CentOS on my Laptop. How do I create a file from bash prompt without using GUI tools?A. Linux / UNIX offer many command line tools and text editors for creating text