tar format (Chen Xu)Go to the original code directory where the software is installed and run make Uninstall. If not, you can also check the MAKEFILE file, which mainly depends on the install part. Find out the path to which the tar-format file is copied, and then enter the corresponding directory to delete it.
1145 customized Linux prompt (Chen Xu)In bash, the prompt is specified through an environment variable $ ps1. Use export $
file.
Get-process> process.txt
>
Append the output content to the specified file.
Dir *. PS1> scripts.txt
2>
Sends errors to the specified file.
Get-process none 2> errors.txt
2>
Append the error to the content of the specified file.
Get-process none 2> save-errors.txt
2> 1
Send the error to the successful output stream.
Get-process none, powershell 2> 1
If the specified file alre
Copy the/etc/profile file ~ /. Modify the. profile file to customize your own shell environment.
/uTo the User Name of the current user.
/hExtend to the Host Name (until the first vertex in the DNS name ).
/wExtended to the current working directory (~Indicates the user's home directory ).
/tExtended to the time (HH: mm: SS) in the 24-hour clock format ).
/AExtended to the time (HH: mm) in the 24-hour clock format ).
/e(ASCII escape characters) pass more advanced options to the terminal window.
1. Set the environment variable histsize so that it can save 10,000 command history.A: Vim/etc/profile, search for histsize, change 1000 to 10000, then save the exit, and then execute source/etc/profile to make it effective.[Email protected] ~]# echo $HISTSIZE1000[[email protected] ~]# histsize=10000# temporarily modified[Email protected] ~]# echo $HISTSIZE10000[Email protected] ~]# cat/etc/profile |grep histsizehistsize=1000Export PATH USER LOGNAME MAIL HOSTNAME histsize Histcontrol[[email prot
is also displayed.Set-tuDisable the check for undefined variables during replacement.Use echo $-to display all configured shell options.(5) User Startup File. profilePATH = $ PATH:/usr/loacl/bin; export PATH(6) shell Environment VariablesHere is an example of what is an environment variable, but it is still not an environment variable. In my understanding, environment variables are similar to macro definitions, or an environment variable is a global or local variable acting on the system.CDPATH
file systems are virtual and do not occupy the actual disk space,
Their contents are stored in the memory.
mkdir -pv $LFS/{dev,proc,sys,run}mknod -m 600 $LFS/dev/console c 5 1mknod -m 666 $LFS/dev/null c 1 3mknod -m 444 /dev/random c 1 8 mknod -m 444 /dev/urandom c 1 9 mount -v --bind /dev $LFS/devmount -vt devpts devpts $LFS/dev/pts -o gid=5,mode=620mount -vt proc proc $LFS/procmount -vt sysfs sysfs $LFS/sysmount -vt tmpfs tmpfs $LFS/runif [ -h $LFS/dev/shm ]; then mkdir -pv $LFS/$(readlink $
enter another shell
[root@shuai-01 ~]# pstree |grep bash |-sshd-+-sshd-+-bash | | `-bash---bash-+-grep | `-sshd---bash
The new shell is the sub-shell of the previous shell .?Define a global variable (export) in the current shell)
[root@shuai-01 ~]# export b=123[root@shuai-01 ~]# echo $b123[root@shuai-01 ~]# bash[root@shuai-01 ~]# echo $b123[root@shuai-01 ~]# pstree |grep bash |-sshd-+-sshd-+-bash | | `-bash---bash---bash-+-grep
First, prevent repair errors and fail to restore the first backup cp. bashrc. bashrc. bak then paste the following two commands to your. under bashrc's prompt (UID) amp; User \ e [1; 32 m quot; | User quot; \ e [1; 31 m quot; PS1 quot; \ [\ e [1; 32m \] \ u \ [\ e [0; 34 first, prevent repair errors and fail to restore the first backup
Cp. bashrc. bashrc. bak
Then paste the following two commands to your. bashrc prompt.
(UID) User = "\ e [1;
Using SharePoint fast, because it is verified by SSH, there will be a certificate expiration problem. I think it is because the distributed security mechanism is taken into account when fast4sharepoint is designed, therefore, both fast and SharePoint require certificates for secure communication.
How can I generate a new certificate and import it to fast?
1. You need to use powershell to enter c: \ fastsearch \ Installer \ scripts
2. view the current certificate status
Ping-spenterpri
1, generally $name[' Tom ' and $name[tom] are the same; but the key without the quotation mark cannot be distinguished from the constant, such as: Define (' Index ', 5); $name [' Tom '] and $name[tom] are different
2, the variable in double quotes is generally used in {} is a good habit, such as: Echo "{$name}";
3. Array $name = Array (' Tom ', ' Jim ', ' Alice '); and $username = [' Tom ', ' Jim ', ' Alice '];
4, the array with the = symbol to specify an initial value, followed by the key v
1. Command prompt user@ubuntu-hansee:~/test$ global variable PS1 ps2 echo $PS 1: \[\e]0;\[emailprotected]\h: \ w\a\]${debian_chroot:+ ($debian _chroot)}\[emailprotected]\h:\w\$ echo $PS 2: > A few basic hints meaning: \u: User \h: local hostname \w: Current working directory name \T:24 hour time \t:12 hour system Modify the command prompt for the current terminal Direct assignment: ps1= "[\t
After the password expires, change the password to the original password, the server a lot of work, write scripts to complete.After logging in, modify the prompt to: doraemon# convenient expect matchModify Lang=c, prompt for English to prevent interference: #!/usr/bin/expect################################################################ connecting the remote host proc Do_login {passwd} {Set timeoutTenSet Done 1Set Timeout_case0set PS1 {
command type3. Variablesecho $ variable NameEcho $PATH (in Linux, uppercase variables are typically system-predefined variables)The system defines the shell's environment through predefined environment variables, and env displays the main predefined variable contents of the system, which can display the environment variables and user-defined variables.Root user command front prompt is #, normal user command prompt is $With the set command, there is a PS1
/bin/vim3When export does not add any variable names, all variables are declared.Command: Pstree view current shell in that layer #pstree |grep bashFor all users in the system to be able to use after logging in, you need to add the export variable name = variable content at the bottom of the/etc/profile file and then shipThe line source/etc/profile in effect.3. System and User's environment variable configuration fileSystem files used in the system to specify environment variables have path HOME
Open ~/.BASHRC to see what the command prompt is: \[email protected]\h\w\$\u represents the user name, \h represents the host name, \w represents the current directory, \$ represents a command prompt (ordinary user $, Super User #)This command prompt is a bit long, very in the way, \[email protected]\h can be deleted, only show \w\$ is very goodInstead: ps1= ' \[\033[1;3;32m\]\w\[\033[31m\]\$\[\033[0m\] 'If you change to
Variables are divided into system variables and user-defined variables, and their profiles are of course divided into system environment variable configuration file and user environment variable control file.1. Specify the configuration file for the environment variable[Email protected] 111]# Vim/etc/profileWe recommend that you create a *.sh file under/ETC/PROFILE.D to modify2. Variables in the configuration file that modify the global parameters[Email protected] 111]# vim/etc/profile.d/path.sh
–forceHow configuration Files worka PowerShell configuration file, is just a . PS1 the script file, just it every time you start Shell when you start together. You can think of a configuration file as a login running PowerShell script or Exchange Management Shell. In the configuration file, you can add custom aliases, custom variables, load other modules, and add custom functions. In front, we used the new-item command to create a new configuration s
The shell terminal only displays the user name, hostname, working directory by default, and sometimes we need to simply tweak the information displayed on the shell terminal to make the work more efficient. For example, we can add time to the shell terminal so that we calculate the time of the script execution as follows: [[emailprotected] src]$echo $PS1 [\[emailprotected]\h \W]$ #读取默认终端显示信息 [[emailprotected] src]$export
PS1 re-assigns the value, using = assignment. We change h to uppercase H,W to lowercase w, and note that you want to hit a space after $ to make the format beautiful. 650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M01/9D/13/wKioL1l5qfGhdZyYAAAekejWHTo607.png "style=" float : none; "title=" Image011.png "alt=" Wkiol1l5qfghdzyyaaaekejwhto607.png "/>We found that the hostname and user name were displayed as complete.PS:$ Two should be entered i
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.