[Gambas-user] some bash commands I wish move in gambas

Brian G brian at westwoodsvcs.com
Thu Oct 5 17:35:00 CEST 2023


You know you can call directly the c library functions to do some of these things, much faster that exec and shell

"Failure is the key to success; 
 each mistake teaches us something"  .. Morihei Ueshiba
Brian G

----- On Oct 5, 2023, at 3:26 AM, T Lee Davidson t.lee.davidson at gmail.com wrote:

> On 10/5/23 04:39, roberto.premoli at tiscali.it wrote:
>> hello,
>> in my soft i used the followed bash command
>> 
>> cp
>> tar -cvzf
>> tar zxvf
>> rm -rf
>> ls -la
>> mv -f
>> md5sum
>> scp
>> ssh
>> find
>> cat
>> 
>> I run them using Exec, they works fine.
>> Now I almost complete the program and I think it will be more elegant, more
>> "right" to use only gambas commands (if there are)
>> 
>> and not external programs.
> 
> There are Gambas file and directory functions that can be substituted for cp,
> rm, ls, mv [https://gambaswiki.org/wiki/cat/file].
> You might be able to create your own 'find' function using RDir and others. For
> 'cat', you read and write using streams.
> 
> For md5sum, there is the gb.hash component. There is also gb.compress though I
> don't think it handles tar files.
> 
> I don't know of any Gambas equivalent for scp or ssh.
> 
> 
> --
> Lee
> 
> 
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----


More information about the User mailing list