Linux-Bulgaria.ORG
навигация

 

начало

пощенски списък

архив на групата

семинари ...

документи

как да ...

 

 

Предишно писмо Следващо писмо Предишно по тема Следващо по тема По Дата По тема (thread)

Re: lug-bg: X-problem - bash script


  • Subject: Re: lug-bg: X-problem - bash script
  • From: v_valchev@xxxxxxxxxx (Valentin Pavlov)
  • Date: Mon, 9 Oct 2000 09:28:46 +0200



Estestveno che stava i s cut dori bez da znaesh dylzinata
eto taka:
VAR1 = `echo $VAR; cut -f 1 -d ' '`
VAR2 = `echo $VAR: cut -f 2 -d ' '`
poqsnenie
'-f' e field
'-d' e delimeter
taka che "-f 1 -d ' '" znachi pyrviq token, kato za delimiter se izpolzva
interval

----- Original Message -----
From: "Nikolay Kabaivanov" <ntk@xxxxxxxxxx>
To: <lug-bg@xxxxxxxxxxxxxxxxxx>
Sent: Sunday, October 08, 2000 1:41 PM
Subject: Re: lug-bg: X-problem - bash script

>
> EDAC wrote:
> >
EDAC
> > P.S. Oshte edin typ vypros. Pisha si bash script. Imam promenliva,
> > koiato se systoi ot dve dumi razdeleni s interval. Kak da rygna dvete
> > dumi pootdelno v dve drugi promenlivi. Naprimer, imam VAR="abc def"
> > i iskam da polucha VAR1="abc" i VAR2="def". Kak da go napravia?
> Zdrawej
> ne sum specialist, no az bih izpolzwal comandata "cut" ako znaesh tochno
> kude iskash da otrezesh dumite i wsicko e s fiksirana dulzina. No naj
> dobre bi bilo s awk, moze bi eto taka :
> $purwa= `echo $dwe_promenliwi | awk '{printf($1)}'`
> $wtora= `echo $dwe_promenliwi | awk '{printf($2)}'`
> Sigurno moze da se naprawi optimizacia i wsicko da stane na 1 red i bez
> printf.
> BYE
> ----------------------------------
> Nikolay Kabaivanov, ntk@xxxxxxxxxx
> University of Rousse, Bulgaria
> ==================================================================
> A mail-list of Linux Users Group - Bulgaria (bulgarian linuxers)
> Otpiswaneto RABOTI !!! : Majordomo@xxxxxxxxxxxxxxxxxx UNSUBSCRIBE LUG-BG
> http://www.linux-bulgaria.org/ Hosted by Internet Group Ltd. - Stara
Zagora
>

==================================================================
A mail-list of Linux Users Group - Bulgaria (bulgarian linuxers)
Otpiswaneto RABOTI !!! : Majordomo@xxxxxxxxxxxxxxxxxx UNSUBSCRIBE LUG-BG
http://www.linux-bulgaria.org/ Hosted by Internet Group Ltd. - Stara Zagora



 

наши приятели

 

линукс за българи
http://linux-bg.org

FSA-BG
http://fsa-bg.org

OpenFest
http://openfest.org

FreeBSD BG
http://bg-freebsd.org

KDE-BG
http://kde.fsa-bg.org/

Gnome-BG
http://gnome.cult.bg/

проект OpenFMI
http://openfmi.net

NetField Forum
http://netField.ludost.net/forum/

 

 

Linux-Bulgaria.ORG

Mailing list messages are © Copyright their authors.