Quick Country

A few days ago, I started to implement shinobar's firstrun into Woof, but I was customizing it so much that I realised that I would be better off writing it from scratch. So, I created Quick Setup, script 'quicksetup'.

These are symlinks to 'quicksetup':

quickcountry
timezone-set
chooselocale


The last two replace the scripts of the same name, and work with or without X.

I implemented the country settings, same as shinobar's firstrun, but when I started on the X setup and hostname, I had second thoughts. I implemented resolution selection by means of xrandr, however I don't think it appropriate to be offering the xrandr solution as the first choice. Also, I don't know if this is the right place to be setting the hostname.

There is a variable, DISTRO_XORG_AUTO in /etc/DISTRO_SPECS. If 'yes', then X starts automatically at first boot, otherwise the Xorg Wizard is run. Wary is built with 'no', so behaviour is as before, locale, keyboard and Xorg Wizard text-mode dialogs.

However, Racy has a recent version of Xorg and is built with 'yes', so now at first boot execution goes straight to the desktop, no text-mode dialogs at all. However, instead of bringing up the full Quick Setup, the symlink 'quickcountry' is executed, which only brings up the country settings:



After clicking the 'OK' button, a restart of X is performed if necessary, then the welcome1stboot is offered -- I intend to redesign that to offer the Xorg Wizard more prominently. Setting hostname will be offered somewhere in the network setup Wizard.

Script /usr/sbin/quicksetup is internationalised, and /usr/sbin/quicksetup.pupdev has full instructions for creating a language translation file.


Posted on 19 Oct 2011, 17:09


Comments:

Posted on 19 Oct 2011, 17:43 by linuxcbon
faster bootup
I have an idea, why not remove choose locale, choose keyboard, choose timezone, choose graphics from boot ?
These can be later chosen by the user, in jwm.
Boot then can be fast and easy.
BTW I am testing but testing is a hard job.


Posted on 19 Oct 2011, 17:56 by Terryphi
Resolution selection
Good idea to give Xorg Wizard more prominence.

I have found it impossible on my hardware to go straight to the desktop with a resolution of 1024x768 - which is what my eyes require!

Improving resolution selection should be a priority.
Xorg always seems to go want to go to a default resolution.


Posted on 19 Oct 2011, 18:24 by shinobar
countrywizard
If you want to separate the country settings from the firstrun, you can just call /usr/bin/countrywizard.qs.

In lucid and slaco, the firstrun.sh or /root/Startup/fullstart calls /usr/bin/firstrun which offers country settings with hostname and X resolution.
But you can call /usr/bin/countrywizard.qs there, you are offered only the country settings.


Posted on 19 Oct 2011, 18:37 by shinobar
countrywizard, firstrun, xrandshell
my firstrun-1.9.pet has /usr/bin/firstrun, which is a symlink to /usr/sbin/countrywizard.qs.
The pinstall.sh overwrites /usr/sbin/countrywizard and /usr/sbin/xrandrshell both the symlinks to /usr/sbin/countrywizard.qs.
That is all the 3 are symlinks to the same script /usr/sbin/countrywizard.qs.
But they shows different behaver.

countrywizard offers only country settings. xrandrshell offers X resolution, and firstrun offers both plus hostname.


Posted on 19 Oct 2011, 18:51 by Iguleder1
Preinstalled Seamonkey/Firefox extensions
Barry, I found a way to pre-install extensions for Firefox and Seamonkey without having to create a profile first!

It's really simple - I found out that xpi extensions are zip archives. Just unzip an extensions, open install.rdf and get its ID, which is a GUID.

In the case of TorButton, it's "{e0204bd5-9d31-402b-a99d-a6aa8ffebdca}".

Here's how to pre-install TorButton for all users, if so (assuming Firefox is located in /usr/local/apps/firefox):
install -m644 -D torbutton-current.xpi $INSTALL_DIR/usr/local/apps/firefox/extensions/\{e0204bd5-9d31-402b-a99d-a6aa8ffebdca\}.xpi


Very simple and works great here, with the advantage of being future-proof and easy.


Posted on 19 Oct 2011, 18:53 by shinobar
Xorg autostart
As you know Xorg can autostart in newer version as Lucid, slaco and Racy.
But also the older Xorg in Puppy/Wary can.

You can see the solution in the Wary-511-01q. It starts Xorg with vesa.
Of course some hardwares have difficulty in autostart X, regardless the Xorg is newer or old.
The Wary-511-01q also has a solution for that.

The Wary-511-01q has the graphical boot menu thanks to the Grub4Dos and has a boot option, 'Safe mode'.
The safe mode boots Puppy with the boot option pfix=nox. It leads to the command line and offers xorgwizard with a menu dialog.
Please see how it works the Wary-511-01q with the 'Safe mode' boot option.
http://shino.pos.to/linux/wary/


Posted on 19 Oct 2011, 19:06 by shinobar
xrandr, hostname
Barry> I don't think it appropriate to be offering the xrandr solution as the first choice. Also, I don't know if this is the right place to be setting the hostname.
I agree the xrandr solution is not beautiful.
As for the hostname, it is not proper to offer it in network setup because in many case the internet connection is made automatically without wizards.


Posted on 19 Oct 2011, 22:33 by abushcrafter
I Prefer The Old CL Wizards
I have to restart X because I use the UK keyboard layout. So this is just a nuisance. Will there be the option of the good old CL wizards please?

btw how do I change my password for comments on your blog?


Posted on 19 Oct 2011, 24:37 by aragon2
Cl wizards
@abushcrafter

There is a variable, DISTRO_XORG_AUTO in /etc/DISTRO_SPECS. If 'yes', then X starts automatically at first boot, otherwise the Xorg Wizard is run. Wary is built with 'no', so behaviour is as before, locale, keyboard and Xorg Wizard text-mode dialogs.

Aragon


Posted on 19 Oct 2011, 24:54 by Adi
Changes in Romanian keyboard
Please consider Romanian "standard" keyboard layout an in Ubuntu 11.10 (similar to us keyboard) for the next puppy distros. The old layout (similar to German layout) is obsolete.


Posted on 20 Oct 2011, 4:15 by gcmartin
Something that works
Hi Barry.

I fully understand that there are multiple approaches to setup.

But some of us will share that FirstRUN works. And instead of having a newbie/user go to several places in the plethora of desktops menus and tools for some of the simple stuff, you have to admit, that Shinobar's simple methods does this all in one single screen. Furter, it allow any user if they need to make a change, they can come to the one screen assure that it will relfect the current system setting, for adjusting or changing behavior.

Might you consider a single screen for newbies (which was the approach you started with).

The ONLY thng FirstRUN was missing was a password set tool. It had packed about 1 years of study prior to going into it for an organized single screen approach to booting. September,2010, it arrived on the scene demonstrating a practical method for boot without multiple user interventions before desktop.

No other distro or OS on the planet had done that up until then.

If you feel multiple screens is a better approach, we'll follow, but, I think your original approach was an overall best for all.

Hope this helps


Posted on 20 Oct 2011, 4:20 by gcmartin
Something that works
I thnik your original was boot to an X desktop and provide a single screen for system tailoring. That's what FirstRUN had given us.

Hope I got that right.


Posted on 20 Oct 2011, 6:12 by abushcrafter
Sorry
@aragon2 Sorry. You know I read that more than once and that critical last sentence did not go in because I was trying to be too quick and I thought it meant Barry had switch to the new X GUI. I skimmed over the last 2 words! Stupid me! Thank you for using your precious time to give me a kick in the right direction. :)


Posted on 20 Oct 2011, 7:29 by BarryK
Re Quick Setup
Thanks for the feedback.

You might be thinking, why am I inventing the wheel when shinobar has done such a good job? Well, that is not really happening -- I am studying shinobar's code very carefully and importing blocks of it where appropriate. In many cases, even where I have rewritten the code, it is inspired by, and guided, by the ideas and code that shinobar has created.

Yes, I have slept on it, reconsidering today, might bring back the X and hostname setup into the first window. Running the script with it's full name 'quicksetup' achieves this -- although it is not quite complete yet.

Yes, many people are going to prefer the "old" text-mode dialogs, and even when the default is automatic X startup I will offer a fallback to the text-mode dialogs.

Regarding setting the resolution by xrandr, it is less than satisfactory as it changes the resolution after X has started, causing an extra delay and screen restart/flicker -- it would be better to get xorg.conf to force X to use the required resolution.
But, if that is what is really wanted up-front in the "firstrun" window, I suppose that I can live with that -- but it bothers me that many people will use it instead of fixing X "properly".



Posted on 20 Oct 2011, 8:21 by GCMartin
Trying to help
Barry, in trying to help this effort of a single startup user selection screen I posted this new thread asking for ideas from the community. http://www.murga-linux.com/puppy/viewtopic.php?p=574540#574540
Hopefully it will provide a single place where ideas can be provided to you.

Hope this helps


Posted on 20 Oct 2011, 8:36 by shinobar
changing keyboard layout
abushcrafter> I have to restart X because I use the UK keyboard layout.

You need not restart X when you only change the keyboard layout with my code. Try firstrun-1.9.pet.
http://www.murga-linux.com/puppy/viewtopic.php?t=58312



Posted on 20 Oct 2011, 8:18 by scsijon
setup
my 2 bob,

Maybe with so many variations in ideas, all we just need is another puppy pfix tag. ie pfix=autox uses firstrun or barry's equivalent.

scsijon


Posted on 20 Oct 2011, 8:20 by BarryK
keymap-set
shinobar's 'keymap-set' script is brilliant coding, it has gone into Woof as-is.

I confirm, yes, the script updates keyboard layout without having to restart X.



Posted on 20 Oct 2011, 8:43 by 01micko
pfix=autox
haha! i like it scsijon!

Some machines don't like booting to X, some do, this would be a great idea. However, having firstrun (aka quicksetup) needn't depend on the setup of X. In slacko xorgwizard runs first (console mode) then shino's first run (very slightly modded) runs, then welcomefirstboot.


Posted on 20 Oct 2011, 9:00 by abushcrafter
Re: No Restart X For Change Of Keyboard Layout
<blockquote>20 Oct 2011, 8:36 by shinobar
changing keyboard layout
abushcrafter> I have to restart X because I use the UK keyboard layout.

You need not restart X when you only change the keyboard layout with my code. Try firstrun-1.9.pet.
http://www.murga-linux.com/puppy/viewtopic.php?t=58312 </blockquote>

Great that is a nice improvement.


Posted on 20 Oct 2011, 15:51 by Adi
Why not a puppy appstore
I can hardly find all pets that can be usefull after my first install. They are often in the forum. Puppy package manager has less choices than suitable pets. I should like to see all them in a single place...


Posted on 20 Oct 2011, 15:53 by GCMartin
Shinobar's connection to WARY
Don't know why i didn't mention this earlier. But, hasn't all of Shinobar's work over the 18 months have Barry's WARY running with FirstRUN?

Probably should have mentioned this earlier.


Posted on 20 Oct 2011, 18:19 by BarryK
Setting hostname
shinobar stated:

As for the hostname, it is not proper to offer it in network setup because in many case the internet connection is made automatically without wizards.

The problem with that statement is that if the connection is made automatically at first startup, then it is already to late to set the hostname in 'firstrun'. It would make no difference setting hostname by a later network setup tool.

But, you probably mean that as the connection has been automatically established, the user might not bother to run any other network setup tool, so having the hostname setting up-front will at least bring that to their attention.

...I think that I have understood your comment correctly.



Posted on 20 Oct 2011, 18:22 by BarryK
Symlinks to 'quicksetup'
The full complement of symlinks to 'quicksetup' are now:

chooselocale
countrywizard
quickcountry
timezone-set
xrandrshell




Posted on 20 Oct 2011, 19:10 by 01micko
hostname
We now have a unique hostname. It is set before puppy has booted. Why not just have a note that states if HOSTNAME is changed it is not fully stuck until a saved reboot is made?
It may be a better option in the shutdown wizard.
Remember.. the kernel won't know it's changed until a reboot. This could be critical in some situations.
My 2c


Posted on 20 Oct 2011, 23:29 by GCMartin
Hostname
From my user perspcetive, FirstRUN offer the opportunity to set this PC name to something I would recognize from say Windows/MAC shuld it show in their network screen. I may choose Suze, Edward, etc.

What I see in Slacko, Lighthouse, I think some of Pemasu's work and others, is that when this run, most (some all) of the Puppy fields and files are set to reflect the new hostname. (In some of these cases, where FirstRUN is used, it has required me to exit X to Prompt, and enter logout or enter "login root" to redrive the system. Then I find that all of the fields are, now, properly set so that any Puppy application will find consistent hostname information.

Further should there be a need to later change the hostname should I need to do it after system has been running awhile, I simply come back to FirstRUN (Menu>SEtup>Personalize Settings) and redrive the process with the new hostname.

Seems that the combination of Shinobar,01Micko, and TaZoC have collaborated to address this in the distros they produce.

Understanding its importance in one thing, but implementing has been a bit of a task in the community until these distro developers began to address this.

Hope this helps.