first time blogging to share some recent work imagenet Introduction
Imagenet is currently the world's largest image recognition of the database, the database contains a large number of image information, and these images have a basic tag information,
1, to determine whether the child process execution end
Sometimes after we invoke the shell in Java, the subsequent operation can only continue if the process subprocess ends normally, so we need to determine when the process processes are
What is a bean Shell BeanShell is a scripting language that conforms fully to the Java syntax and has some of its own syntax and methods; BeanShell is a loosely typed scripting language (this is similar to JS); BeanShell is written in Java, a small,
From the "Linnux program design," the second chapter, from one by one to knock out, the conclusion is that a few s did not come out effect
#。 /bin/sh and #. There's a difference,/bin/bash.
The first direct typing is the former, always output some-E,
When you extract or filter text from a file or command output, you can use regular expressions (R E), which are collections of special or not very special string patterns.
^ matches only the beginning of the line$ only match end of line* Only one
There are several main ways to do this:
echo "$str" |awk ' {print length ($)} 'Expr Length "$str"echo "$str" |wc-cBut the third one will be 1 more, maybe the terminator is counted.There are three ways to determine that a string is empty:If ["$str" =
Variable permutation command permutation formula substitution reference use backslash implementation reference use single quotation marks with double quotes
variable Substitution
There are four forms of substitution for variable permutationsSyntax
For a host system, there will be some inaccessible users in the system, but they must also exist, what we call the inability to log on, is that this user can not use bash or other shell to login to the system, not that this account can not use other
The loop structure under the Shell is Class C, also has a for loop, while loop, in addition, the shell also has a until loop. For Loop the basic syntax for a for loop
For variable in {list}
do
statement1
statement2
... Done
The syntax
The company does not have fixed IP, need to test the third party asynchronous callback interface (third party server How to find the company intranet machine); Baidu Search for "intranet penetration" results are mostly peanut shells, but this
forwarding https://my.oschina.net/weiqingbin/blog/190929
You can set the following options when you start Impala-shell to modify the command execution environment. Note:
These options are different from the configuration options for the Impalad
Shell echo CommandThe echo command of the Shell is similar to the echo command of PHP, and is used for the output of strings. Command format:echo stringYou can use echo to achieve more complex output format control.1. Display normal string:echo "It
Tips Summary:String comparison with double brackets [[]]; arithmetic comparison with single brackets []--left and right spacesArithmetic operations with double parentheses (()); Shell commands and output parentheses ()--left and right without
If statement1, according to the file type to judge-d file) to determine if the file exists and is a character device file (the character device is true)-e file) to determine if the file exists (exists as true)[-e/root]echo $? The output is 0 #判断为真,
1, numeric and numeric expressionsAWK does not provide a string-to-number function, but awk is simple: Add a 0 to the string, such as S = "123", then N = 0 + S, and assign the number 123 to N.2. How to print the first few linesHead-n n filename#
Functions: Code snippets that implement standalone functionalityfunction is only executed when calledSyntax One:function f_name{function body}Syntax Two:F_name () {function body}The return value of the function:Default function return value:
Shell Multi-Process basics
Code block: With {} as a whole
& function: Put the command in the background processing, idle out the current console for other operations
Wait command: Waits for the parent process to execute the
13 Basic IF statementsFormat 1:if condition; Then statement; FiExecution result is 5Format 2:if condition; Then statement; else statement; Fi#!/bin/basha=5if [ $a -gt 10 ];then echo $aelse echo 0fiExecution result is 0Format 3:if ...; Then ...; Elif
First of all, the shell script you wrote must be correct,Second, the reason for the inability to run: because the line break under Windows is two bytes, and you upload the Linux,linux under the line is two bytes, so the compilation of the wine is
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.