Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
my idea for GUI etc-update [in progress]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
standsolid
Apprentice
Apprentice


Joined: 27 Aug 2002
Posts: 183
Location: Carlsbad, CA, USA

PostPosted: Sat Oct 25, 2003 9:43 pm    Post subject: my idea for GUI etc-update [in progress] Reply with quote

EDIT 11/07/03:
guitoo Etcetera, a gui etc-update replacement/enhancement is now available at https://forums.gentoo.org/viewtopic.php?t=103540 for your enjoyment. I will make updates available in that thread. I do need help too :)

------------------------------------------------------------------

My biggest pet peeve about gentoo is it's (IMHO) clumsy etc-update tool. I alwyas though there could be a "Better" way of doing it. I was really excited to see cfg-update -- but it isn't quite what I wanted.

This tool will be part of a series of tools I'm going to call "Guitoo" (pronounced gooey-too) that will be a set of tools for a user to administer their Gentoo system from a graphical environment.

I made a sample of my idea, that I plan on making, the gui for etc-update.

[img:8d8054ccb2]http://standsolid.com/etc-update-idea.png[/img:8d8054ccb2]
Figure 1 - GuiToo Kup Displaying some files it will process

Here's how it (will) works,
When you execute the program (I call it GuiToo Kup), it brings up the dialog in Figure 1. That dialog preforms the task of etc-update (by searching through config paths for a ._cfg_??????* file) and displays the current files in a list. the "Action" column contains a pixmap which is initially blank. When that column is clicked, it is changed to a small icon, such as the checkmark. Each time a user clicks, it cahgnes the icon in tha column in the following order

1. Check Icon (replace original with update)
2. No Icon (Delete update and Keep Original)
3. Up Icon (Interactively merge with kdiff3 or xxdiff whatever the user likes)
4. Blank space (do nothing)

After the user is done, he might want to click "Preview" to see a list ot changes that will be made to his system. Then, the user clicks "Execute" and the selected actions are performed. The user will be presented with KDiff3 (configurable) on the files that he selected to Interactively merge.

After hte process is complete, a message box is shown saying "Files successfully updated" with any errors that occured along the way.

I'm thinking that I'm going to make this in Kommander for KDE (that's how I made the dialog) -- but it seems like i might need soemthing with more power (possibly PyQt or even C++). I really don't want toamke it in Kommander becaseu ti needs KDE libs ad quant to be installed. But i do wnat to make this with Qt at least. I'm not a very experienced programmer (if you can even call me that) -- but i think this would be a nice project to start my linux development. I am but a mere scripter (bash, perl, VB, javascript, some php), but would like to extend my "programming" powers to some real apps. Any pointers on where to learn programming for linux would be appriciated.

So, What do you all think of this? Good Idea, bad Idea? Am I duplicating work in progress (besides cfg-update)?
Encouragements, Flames?
_________________
see gentoo differently... --> [[gui tools for gentoo linux]]<--


Last edited by standsolid on Sat Nov 08, 2003 6:25 am; edited 3 times in total
Back to top
View user's profile Send private message
wrc1944
Advocate
Advocate


Joined: 15 Aug 2002
Posts: 3435
Location: Gainesville, Florida

PostPosted: Sat Oct 25, 2003 10:31 pm    Post subject: Reply with quote

I really liked the cfg-update script, and I think this is also a good idea. Please post it when it's done- I'll certainly give it a try, and I would think many others who like gui tools and utilities will use it, too. Choice, and lots of ways to accomplish the same thing is what Linux is all about.

wrc1944
_________________
Main box- AsRock x370 Gaming K4
Ryzen 7 3700x, 3.6GHz, 16GB GSkill Flare DDR4 3200mhz
Samsung SATA 1000GB, Radeon HD R7 350 2GB DDR5
OpenRC Gentoo ~amd64 plasma, glibc-2.36-r7, gcc-13.2.1_p20230304
kernel-6.8.4 USE=experimental python3_11
Back to top
View user's profile Send private message
ba747heavy
Apprentice
Apprentice


Joined: 11 Aug 2003
Posts: 216
Location: New Mexico, USA

PostPosted: Sat Oct 25, 2003 10:33 pm    Post subject: Reply with quote

Your idea looks like a winner, I hope you keep it up 8)
_________________
Fred Clausen
"leet [speak] is a cry for help from a shallow mind" - Doomwookie Jan 05
Back to top
View user's profile Send private message
idl
Retired Dev
Retired Dev


Joined: 24 Dec 2002
Posts: 1728
Location: Nottingham, UK

PostPosted: Sat Oct 25, 2003 10:52 pm    Post subject: Reply with quote

It looks great, but whats wrong with etc-update as it is now? I find its perfect for the job.
Back to top
View user's profile Send private message
aethyr
Veteran
Veteran


Joined: 06 Apr 2003
Posts: 1085
Location: NYC

PostPosted: Sun Oct 26, 2003 2:53 am    Post subject: Reply with quote

Cool, I'm not 100% sure I'd use such a tool, but it might be easier for some people.

One recommendation, I like how sourceforge does their diffs in CVS, you should see if you can have some kind of color-coded way to show the differences between the old file and the new file.

For instance:
http://cvs.sourceforge.net/viewcvs.py/gaim/gaim/src/dialogs.c?r1=1.551&r2=1.552&sortby=date

Also, you might want to consider carrying over the functionality of dispatch-conf since it seems to make updating easier sometimes when you don't have to worry about files you never modified in the first place.
Back to top
View user's profile Send private message
standsolid
Apprentice
Apprentice


Joined: 27 Aug 2002
Posts: 183
Location: Carlsbad, CA, USA

PostPosted: Sun Oct 26, 2003 4:53 am    Post subject: Reply with quote

thanks for your replies and ideas everyone :) i'm going to experiment first using kommander then I will move on to bigger and better things (c++. i got a book on QT programming)

port001 - the reason why I don't like etc-update is because of it's interface. it's not very intuitive when i emerge 80 new files and I have 60 files to look at. i have to type 1 then -2 then type 2.... it a pain for me. even if this wasn't in GUI i think it would be good.
_________________
see gentoo differently... --> [[gui tools for gentoo linux]]<--
Back to top
View user's profile Send private message
Retriever II
Tux's lil' helper
Tux's lil' helper


Joined: 07 Sep 2003
Posts: 93
Location: Northampton, MA, USA

PostPosted: Sun Oct 26, 2003 5:53 am    Post subject: Reply with quote

The command line is fine until you need to interactively merge the files ... everything just went downhill from there (for me, anyway). That's where the GUI version might prove much nicer.
Back to top
View user's profile Send private message
slarti`
Retired Dev
Retired Dev


Joined: 20 Sep 2003
Posts: 376
Location: UK

PostPosted: Sun Oct 26, 2003 11:49 am    Post subject: Reply with quote

I agree with Retreiver II. It would be nice to see some GTK interfaces for some of these Gentoo-specific apps though.
_________________
Gentoo/AMD64, shell-tools, net-mail, vim, recruiters
IRC: slarti @ irc.freenode.net
Devspace
Back to top
View user's profile Send private message
geekX
Tux's lil' helper
Tux's lil' helper


Joined: 02 Apr 2003
Posts: 86
Location: Cape Town, South Africa

PostPosted: Sun Oct 26, 2003 9:08 pm    Post subject: Reply with quote

Why not just use Meld in stead of vimdiff? That way no-one will have to do any new coding.

It is a gtk2 visual diff/merge tool written in python and even my vim-zealot friends are impressed by it. It really makes it easy to apply the needed changes and ignore the lines you changed deliberately yourself.

I'm sure there is a way to make etc-update use meld automatically, but I can't remember how off the top of my head.
_________________
Sometimes I feel like Superman.
Sometimes I'm just recuperating.
Back to top
View user's profile Send private message
Lazlo
n00b
n00b


Joined: 25 Jan 2003
Posts: 66
Location: Gl. Lejre, Denmark

PostPosted: Sun Oct 26, 2003 10:07 pm    Post subject: Reply with quote

My idea might not be crystal clear but here it is:

I would wish that the developers would mark the updates of config files as critical, normal or minor.

If a file is exactly the the same as the one that came with the users installed version the developer should be able to mark the file as recommend replace or recommend merge.

Something like that to help taking the burden of deciding what to do with all the updated config files after a merge.

Sensible defaults.
Back to top
View user's profile Send private message
standsolid
Apprentice
Apprentice


Joined: 27 Aug 2002
Posts: 183
Location: Carlsbad, CA, USA

PostPosted: Mon Oct 27, 2003 11:08 am    Post subject: Reply with quote

OK, so I've been worling on learning C++ and Qt at the same time while not not at work (Qt is EXCELLENT by the way -- very common-sense)

I have (another) prototype running that is Qt and C++ based (not Kommander). It's not much but I'm proud of myself so here's a new screenshot for y'all that I wanted to show off. I got the icons from crystalsvg iconset if anyone was wondering. and I'm using the Plastik style for my widgets.

[img:817774782f]http://standsolid.com/guitoo/idea-c++-103103.png[/img:817774782f]
get it?

If anyone has links to documentation I can read (besides trolltech's site) it would be much appriciated. I currently have O'REILLY's Programming in Qt book which is also excellent. I'm using qt examples to learn all of this code and hope to have a working prototype of this up by the end of the week.

I found a few things Qt can't do taht KDE can that I might like to include -- but I feel that would alienate a lot of users. if yo uuse gnome of flux, why not install a small QT library rather than that HUGE KDE library.

On the other hand, after I get this app all done, I'm going to start on another app that can help a desktop user emerge easier ( using screen or some form of virtual terminal) with options to re-nice and have an icon in the taskbar. But one project load at a time, 'eh?

(bonus prize to whoever gets the joke in the screenshot)
_________________
see gentoo differently... --> [[gui tools for gentoo linux]]<--


Last edited by standsolid on Sat Nov 01, 2003 5:46 am; edited 1 time in total
Back to top
View user's profile Send private message
Evangelion
Veteran
Veteran


Joined: 31 May 2002
Posts: 1087
Location: Helsinki, Finland

PostPosted: Mon Oct 27, 2003 11:36 am    Post subject: Reply with quote

standsolid wrote:
(bonus prize to whoever gets the joke in the screenshot)


"Do Nothing" :lol:
_________________
My tech-blog | My other blog
Back to top
View user's profile Send private message
so
Retired Dev
Retired Dev


Joined: 08 Sep 2003
Posts: 115
Location: Roma

PostPosted: Mon Oct 27, 2003 1:19 pm    Post subject: Reply with quote

standsolid wrote:
the reason why I don't like etc-update is because of it's interface. it's not very intuitive when i emerge 80 new files and I have 60 files to look at.

I agree with you
good idea :!: :wink:
Back to top
View user's profile Send private message
()
l33t
l33t


Joined: 25 Nov 2002
Posts: 610

PostPosted: Mon Oct 27, 2003 2:39 pm    Post subject: Reply with quote

Kompare of KDE-SDK has a color coding scheme which makes it easy to spot differences between two files, btw. I think a GUI could potentially simplify the etc-update task, I find it sometimes a bit difficult to group the different files visually in the console. Also your GUI looks quite neat : ]
Back to top
View user's profile Send private message
andrew_j_w
Guru
Guru


Joined: 28 Jun 2003
Posts: 534
Location: York, UK

PostPosted: Mon Oct 27, 2003 6:08 pm    Post subject: Reply with quote

standsolid: Are those just gui mock-ups, or do you have an actual program that's displays them?

I'd be more than happy to help you produce this application, be it just testing or actual coding. I'm fine with C/C++, Python and QT.

Anyway, just shout if you need anything :D
Andrew
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Wed Oct 29, 2003 3:26 am    Post subject: Reply with quote

port001 wrote:
It looks great, but whats wrong with etc-update as it is now? I find its perfect for the job.

At first I thought that etc-update was hard to understand and use so I wrote cfg-update.
After realising that it should work in CLI mode (without GUI) too, I implemented sdiff in
almost the same way as etc-update does... experimented a bit and actually started to like
the sdiff way of merging!

#For those who hate etc-update:
CLI mode cfg-update uses : sdiff -w 80 -o $file1.merged $file1 $file2
Test it for yourself by running "cfg-update -u" from a virtual terminal
or with "cfg-update --cli -u" from any X terminal. As long as you read
the usage tips, it works without a hitch!

So I guess that if etc-update had a safer automerge function and if it was a bit less cryptic
a lot of users would actually like etc-update... I just rewrote cfg-update so it can do almost
exactly the same thing as etc-update, but with a bit more verbosity and some clear hints to
help users decide what to do, and how to do it. Automerging (overwriting) in cfg-update is
only allowed when the file has not changed after being installed by portage.

etc-update really isn't a bad tool, it just has some rough edges !
Back to top
View user's profile Send private message
standsolid
Apprentice
Apprentice


Joined: 27 Aug 2002
Posts: 183
Location: Carlsbad, CA, USA

PostPosted: Sat Nov 01, 2003 2:12 am    Post subject: Reply with quote

Non-working prototype!

you can now preview guitoo Config (preview release 0.01)

note: it does NOT merge files yet, but it does list of /etc/*_.cfg*_*.

another note: this is my fist c++ project, be gentle :}

the reason i'm uploading this at all is to show what the program will look/feel like and to show that I have been working on it (a little bit at least)

I've been reading a lot about Qt and a lot of examples. in fact, I based some of the code in my project from trolltech's docs (this is OK to do right?). I figured out i'll need to make a class for the listview and each listviewitem as well as create slots and connectors for clicking of the pixmap. I'm really excited to learn all of this stuff and want as many comments as you all can hand out. look at my code, mock my code, contribute your code, say good riddance, say "you rock!".

to "run" the preview,
follow these commands

Code:

# tar zxvf config-preview-0.01.tar.gz
# cd config-0.01
# qmake
# make
# ./guitooConfig
 


there is no installer (as i thought that would be completely useless)

thanks for checking it out (even if it doesn't really do anything)

EDIT:
just realized it would be nicer if i acctually uploaded the source tarball, huh?
http://standsolid.com/guitoo/config-0.01.tar.gz

no promises on this working :)[/url]
_________________
see gentoo differently... --> [[gui tools for gentoo linux]]<--
Back to top
View user's profile Send private message
standsolid
Apprentice
Apprentice


Joined: 27 Aug 2002
Posts: 183
Location: Carlsbad, CA, USA

PostPosted: Sat Nov 08, 2003 12:01 pm    Post subject: works now Reply with quote

oops. meant to post https://forums.gentoo.org/viewtopic.php?t=103540 with the update.

enjoy anyways
_________________
see gentoo differently... --> [[gui tools for gentoo linux]]<--
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum