linux?????shell??C????--?????????
???????????? ???????[ 2013/12/24 16:33:15 ] ????????linux shell ??????
??????shell??time??????????????????????terminal????man time????÷?
????????????????д??????????????????????????????
??????????shell??supershell?????
????system????????
????time??????linux????2?????????batch???????time???????usr/bin/time??????????????????
?????????????????? % supershell command ??????????????????
????command??????????????????????????????
#include <cstdio>
#include <cstdlib>
#include <sys/types.h>
#include <sys/wait.h>
#include <cstring>
#include <unistd.h>
#include <ctime>
#define N 1000
char input[N];
char cmd[N]??tmp[N];
const char sp[]="%U %S %E %F %R %w %W %P";
const char pre[]="/usr/bin/time -o temp.txt -f";
/*get the command from string s?? format "% supershell command"*/
int getToken(char *s)
{
int len = strlen(s);
int i=0;
while(s[i] == ' ' && i<len) i++;
if(s[i]!='%'||i>=len) return -1; //not obey format
i++;
while(s[i] == ' '&& i<len) i++;
if(i>=len) return -1;
char temp[]="supershell";
for(int j=0;j<strlen(temp);++j??++i)
if(s[i]!=temp[j])
return -1;
while(s[i]==' '&& i<len) i++;
if(i>=len) return -1;
return i;
}
|
???????????????????????漰???????????????????SPASVOС??(021-61079698-8054)?????????????????????????
??????
Linux??????DDR????????????Linux?????????????????豸??????????linux???в???????????м??????????????????????????Linux????Linux??DNS????????????γ???????????Linux?????????????Linux????(???)????????Linux ????????????????????????????????Windows???У?Linux???????Linux????????????????Linux iommu??vfio???????Linux????ε???TCP???????Linux?????????????СLinux?·???????????Linux???Jexus?й?Asp.Net Core??ó???Linux?????????Щ??
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11????????
?????????App Bug???????????????????????Jmeter?????????QC??????APP????????????????app?????е????????jenkins+testng+ant+webdriver??????????????JMeter????HTTP???????Selenium 2.0 WebDriver ??????