Welcome, Register for free! or Login below:
EduGeek.net RSS Feeds Register FAQ Members Social Groups User Map Calendar Search Today's Posts Mark Forums Read

*nix

*nix forum sponsored by
*nix Forum Sponsored by Navaho

Powering the backend of many of our networks, unbeknown to many. Linux, Solaris, Unix...

Go Back   EduGeek.net Forums > Technical > *nix
Reply
 
LinkBack Thread Tools Search Thread
Sponsored Links
Old 26-02-2009, 11:49 PM   #1
 
RabbieBurns's Avatar
 
Join Date: Apr 2008
Location: Sydney
Posts: 2,611
australia uk scotland
Thanks: 364
Thanked 225 Times in 124 Posts
Blog Entries: 4
Rep Power: 62 RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future
Default bash to GUI

Ive made a few basic 'frontend' (if you can call them that) bash scripts for some programs that require many -flags where it will prompt for each setting, and then run the program based on the user input.

Similar to the oldschool batch files, which any tom dick and pony could make, there wasnt really a GUI equivelent until AutoIT (as far as I know)

My question is, is there anything a complete newbie like me can use to make a GUI frontend, that will take the options inserted into fields in a GUI, and then launch an external program populating the various flags with what has been entered into the various boxes in the GUI?

Hope this makes sense?/

Cheers

RB
  Reply With Quote
Old 26-02-2009, 11:57 PM   #2
 
powdarrmonkey's Avatar
 
Join Date: Feb 2008
Location: Alcester, Warwickshire
Posts: 3,553
uk uk england
Thanks: 223
Thanked 494 Times in 421 Posts
Rep Power: 106 powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute powdarrmonkey has a reputation beyond repute
Default

Hmm, I don't know if ncurses can do what you're after, it's worth looking at. But I think you'll probably be looking at a more complex language like python and PyGtk, which I think it probably the 'easiest' combination.
  Reply With Quote
Old 27-02-2009, 12:15 AM   #3
 
box_l's Avatar
 
Join Date: May 2007
Location: Herefordshire
Posts: 196
uk
Thanks: 21
Thanked 30 Times in 26 Posts
Rep Power: 11 box_l has a spectacular aura about box_l has a spectacular aura about
Default

try gambas

Gambas - Gambas Almost Means Basic

very like visual basic,

BoX
  Reply With Quote
Old 27-02-2009, 12:17 AM   #4
 
localzuk's Avatar
 
Join Date: Dec 2006
Location: Minehead, Somerset
Posts: 6,636
isle of man uk isle of man
Thanks: 180
Thanked 490 Times in 400 Posts
Blog Entries: 14
Rep Power: 135 localzuk ooh
localzuk ooh localzuk ooh localzuk ooh localzuk ooh localzuk ooh
Send a message via MSN to localzuk Send a message via Yahoo to localzuk Send a message via Skype™ to localzuk
Default

How about building little C Sharp applications with Mono? C Sharp is an easy language to pick up for things like this I'd say.
  Reply With Quote
Old 27-02-2009, 12:23 AM   #5
 
dhicks's Avatar
 
Join Date: Aug 2005
Location: Alton, Hampshire
Posts: 2,779
uk
Thanks: 416
Thanked 315 Times in 265 Posts
Rep Power: 83 dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute
Default

Quote:
Originally Posted by RabbieBurns View Post
is there anything a complete newbie like me can use to make a GUI frontend
A web page. It's the exact processing model you're after - stick a form on the screen, the user fills it in and hits "submit", the data is sent to a web server and calls the command-line application via system() or whatever. All you need is a small web server to listen out on a port (doesn't have to be port 80). Python has a web server module that lets you write a small web server in about 3 lines of code.

--
David Hicks
  Reply With Quote
Old 27-02-2009, 01:53 AM   #6
 
RabbieBurns's Avatar
 
Join Date: Apr 2008
Location: Sydney
Posts: 2,611
australia uk scotland
Thanks: 364
Thanked 225 Times in 124 Posts
Blog Entries: 4
Rep Power: 62 RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future
Default

Quote:
Originally Posted by dhicks View Post
A web page. It's the exact processing model you're after - stick a form on the screen, the user fills it in and hits "submit", the data is sent to a web server and calls the command-line application via system() or whatever. All you need is a small web server to listen out on a port (doesn't have to be port 80). Python has a web server module that lets you write a small web server in about 3 lines of code.

--
David Hicks
I was imagining something that would be distributable, rather than having to have them run a web server seems a bit complicated. Thanks though.

Quote:
building little C Sharp applications with Mono
and
Quote:
gambas
Im afraid I am going to have to look up as I have no clue.

Python again I have not dabbled with. But will give it a look.
  Reply With Quote
Old 02-03-2009, 11:34 AM   #7
 
Arcath's Avatar
 
Join Date: Feb 2009
Location: Lancashire
Posts: 331
uk uk lancashire
Thanks: 20
Thanked 24 Times in 22 Posts
Rep Power: 10 Arcath has a spectacular aura about Arcath has a spectacular aura about Arcath has a spectacular aura about
Default

if your using gnome you could allways use "zenity" your script can bring up a series of simple 1 line input boxes.

Zenity examples

it basically works by putting "var=$(zenity --entry --text "Does this work")", the users input is now in $var
  Reply With Quote
Thanks to Arcath from:
RabbieBurns (04-03-2009)
Old 02-03-2009, 12:11 PM   #8
 
dhicks's Avatar
 
Join Date: Aug 2005
Location: Alton, Hampshire
Posts: 2,779
uk
Thanks: 416
Thanked 315 Times in 265 Posts
Rep Power: 83 dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute dhicks has a reputation beyond repute
Default

Quote:
Originally Posted by RabbieBurns View Post
I was imagining something that would be distributable, rather than having to have them run a web server seems a bit complicated.
No, Python lets you write a web server in a few lines of code, it's the simples thing ever!

--
David Hicks
  Reply With Quote
Thanks to dhicks from:
RabbieBurns (04-03-2009)
Old 02-03-2009, 01:20 PM   #9
 
jinnantonnix's Avatar
 
Join Date: Nov 2007
Location: South Wales
Posts: 1,000
uk uk wales
Thanks: 25
Thanked 139 Times in 121 Posts
Blog Entries: 5
Rep Power: 37 jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold jinnantonnix is a splendid one to behold
Default

RealBasic looks interesting, but it's $75.
REAL Software: REALbasic, Cross-Platform Development Environment


Here's a portal to some free stuff which might be of some use:
Free cross-platform programming Tools, free cross-platform compilers, programming languages, etc.
  Reply With Quote
Thanks to jinnantonnix from:
RabbieBurns (04-03-2009)
Old 02-03-2009, 01:34 PM   #10
 
Arcath's Avatar
 
Join Date: Feb 2009
Location: Lancashire
Posts: 331
uk uk lancashire
Thanks: 20
Thanked 24 Times in 22 Posts
Rep Power: 10 Arcath has a spectacular aura about Arcath has a spectacular aura about Arcath has a spectacular aura about
Default

Is the machine that will be running the bash script a webserver? if it is write a simple PHP page with a form on it, then take the POST data and do this:

system("sh /path/to/script/script.sh -flag \"{$_POST['value']}\")

not sure if using \" will work, or if {$var['var']} will, but you get the idea
  Reply With Quote
Old 04-03-2009, 10:04 AM   #11
 
linuxgirlie's Avatar
 
Join Date: Jul 2005
Location: Kent
Posts: 249
uk uk kent
Thanks: 15
Thanked 5 Times in 5 Posts
Rep Power: 10 linuxgirlie is on a distinguished road
Default

Xdialog is a nice simple frontend for bash scripts.

Xdialog

That is the website, gives you lots of examples so you can copy and paste (just highlight what one you want and the script appears below), its what we use to use before we went web-based and is really simple.

Jo
  Reply With Quote
Thanks to linuxgirlie from:
RabbieBurns (04-03-2009)
Old 04-03-2009, 10:37 AM   #12
 
Gatt's Avatar
 
Join Date: Jan 2006
Location: Rochdale
Posts: 3,447
uk uk scotland
Thanks: 287
Thanked 141 Times in 105 Posts
Rep Power: 62 Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of Gatt has much to be proud of
Send a message via MSN to Gatt Send a message via Skype™ to Gatt
Default

looking at dialog at the moment for servers without X on them...
  Reply With Quote
Old 04-03-2009, 10:39 AM   #13
 
RabbieBurns's Avatar
 
Join Date: Apr 2008
Location: Sydney
Posts: 2,611
australia uk scotland
Thanks: 364
Thanked 225 Times in 124 Posts
Blog Entries: 4
Rep Power: 62 RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future RabbieBurns has a brilliant future
Default

Thanks, looks the business Ill give that a play tonight
  Reply With Quote
Reply

EduGeek.net Forums > Technical > *nix

Similar Threads
Thread Thread Starter Forum Replies Last Post
bash script doesnt like folders with spaces RabbieBurns Scripts 20 12-02-2009 01:28 PM
batch to bash rewrite help needed please RabbieBurns Scripts 4 22-09-2008 09:05 AM
GUI and some help needed MK-2 Windows 4 01-03-2007 06:18 PM
One time runas gui plexer Coding 4 29-07-2006 10:36 PM



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search Thread
Search Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:46 PM.
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.
Copyright EduGeek.net




website uptime

© 2005 - 2009 EduGeek.net
SERVER: 4
no new posts