Whonix Repository GUI Tool (Python)

There is a wizard at GitHub - troubadoour/whonix-repository-wizard

It can be a lot more descriptive than a simple GUI. For the moment there are 3 pages:

1- introduction
2- enable|disable repository
3- select repository

I have put the original whonix_repository text in page 2. I’ll need the text for the other pages in order to adapt the wizard size to the verbosity. If you’d feel like, you could write a manual in there…

Added .gitattributes and Whonix icon.

Could you make the text copyable please?

Worked on the output:

I am not sure what the first screen could say. If we need it at all. Input as always welcome.

Could you add a “will run command…” before actually running that command to terminal beforehand please?

Would it be possible without too much effort to write the the exit code info output message in terminal right after the command was run and before the final info popup?

Do we want a final info popup or would the more canonical way to show a final wizard screen? (The latter would be more difficult, because then we’d need to hide the cancel button and show a “back to beginning” (how to name it?) and an exit button?)

I am not sure what the first screen could say. If we need it at all. Input as always welcome.
Will remove it for the time being. If anyone has suggestions, it's easy to get back.
Could you add a "will run command..." before actually running that command to terminal beforehand please?
As far as I know, that is not possible. The graphic modules are compiled before the script is interpreted, and any print statement is executed after the program has completed. I believe there is qDebug or something similar for that, but I have yet to try it.
Would it be possible without too much effort to write the the exit code info output message in terminal right after the command was run and before the final info popup?
Yes, see below.
Do we want a final info popup or would the more canonical way to show a final wizard screen? (The latter would be more difficult, because then we'd need to hide the cancel button and show a "back to beginning" (how to name it?) and an exit button?)
I will remove the popup (or may be only show it if whonix_repository exit code is non zero). The first intention was to have a last wizard page, but I had to temporarily resort to the popup, because dealing with signals-slots in Qt is tricky, and the (very few) examples are written in C++. It's getting clearer now.

Okay.

No repository rename / url change planned? I am asking, because I want to add it to the Whonix/Whonix project.

No repository rename / url change planned? I am asking, because I want to add it to the Whonix/Whonix project.

No, to me “whonix-repository-wizard” looks fine.

Pushed a completely revamped version. It is more “canonical”.

Added some comments.
https://github.com/troubadoour/whonix-repository-wizard/commit/183867325b4968d522ad1f633d13908660a289ad

Please merge my changes first before editing further. Now we got a merge conflict unfortunately. But I guess you can sort it out.

I have sorted it out the hard way, deleting my local and remote repositories. My origin is now GitHub - adrelanos/whonix-repository-wizard: Whonix APT Repository GUI Tool.

The new version: GitHub - troubadoour/whonix-repository-wizard

Please wait for the next commit. A test line is blocking the script.

One thing that could prevent a few support requests in future…

ERROR: This must be run as root!

Could you make that a graphical popup(?) as well please?

[hr]

Getting an error now for “yes” option.

Traceback (most recent call last): File "usr/bin/whonix-repository-wizard", line 120, in nextId exit_code = self.process.start(command) AttributeError: 'Whonix_repository_Wizard' object has no attribute 'process' Traceback (most recent call last): File "usr/bin/whonix-repository-wizard", line 120, in nextId exit_code = self.process.start(command) AttributeError: 'Whonix_repository_Wizard' object has no attribute 'process'

When doing “no -> back -> no”, these terminal messages are mixed up.

INFO usr/bin/whonix-repository-wizard: Ok, exit code of "whonix_repository --disable" was 0.
INFO usr/bin/whonix-repository-wizard: Ok, exit code of "whonix_repository --disable" was 0

Fixed.

[quote=“Patrick, post:33, topic:635”]When doing “no -> back -> no”, these terminal messages are mixed up.

INFO usr/bin/whonix-repository-wizard: Ok, exit code of "whonix_repository --disable" was 0. INFO usr/bin/whonix-repository-wizard: Ok, exit code of "whonix_repository --disable" was 0 [/quote]
They are not mixed, they are buffered. You can try all four options before clicking “Finish”., there will be four lines (or whatever number of lines, function of the number of times you ran the command).

Still have to add real time writing to stdout from the GUI to print the exit code line right after the command is completed.

Looks very good.

Could you disable the “cancel” button in last one please? (Because at the point the action is already done and cannot be canceled in that technical sense anymore, I think.)

Pushed a few minor commits.

[quote=“Patrick, post:32, topic:635”]One thing that could prevent a few support requests in future…

Could you make that a graphical popup(?) as well please?[/quote]

See https://github.com/troubadoour/whonix-repository-wizard/commit/ccccb86d957f47c0375aa565addd0a5ca598fe7e.

It should be sufficient because it can only happen when whonix-repository-wizard is run from terminal. The GUI is not started at that point.

Or when going to /usr/bin and double clicking on it.

Or when going to /usr/bin and double clicking on it.

Right. I never do that, so I have overlooked it.
https://github.com/troubadoour/whonix-repository-wizard/commit/1d097491c14591f825317008671f8c2a86b743eb

But yet, I cannot start whonix-repository-wizard in /usr/bin from the file manager unless it’s root (Dolphin).

But now it says that it cannot be started as user and that is great. Otherwise there would be no feedback. Works for me.

I asked Jason if he could look at it again.