Welcome to NeoOffice developer notes and announcements
NeoOffice
Developer notes and announcements
 
 

This website is an archive and is no longer active
NeoOffice announcements have moved to the NeoOffice News website


Support
· Forums
· NeoOffice Support
· NeoWiki


Announcements
· Twitter @NeoOffice


Downloads
· Download NeoOffice


  
NeoOffice :: View topic - Shorten/reduce 15-step Upgrade/Install workflow
Shorten/reduce 15-step Upgrade/Install workflow
 
   NeoOffice Forum Index -> NeoOffice New Feature Requests
View previous topic :: View next topic  

Do you agree or disagree that this would be a good improvement?
strongly agree
50%
 50%  [ 1 ]
agree
50%
 50%  [ 1 ]
don't care
0%
 0%  [ 0 ]
disagree
0%
 0%  [ 0 ]
strongly disagree
0%
 0%  [ 0 ]
Total Votes : 2

Author Message
sardisson
Town Crier
Town Crier


Joined: Feb 01, 2004
Posts: 4588

PostPosted: Sat Feb 11, 2012 2:02 pm    Post subject:

pluby wrote:
The one question that I have about running after quitting NeoOffice is will it be too weird to have NeoOffice relaunch after the installer runs? Hopefully relaunch is no big deal but I ask the question because there is no way to turn off the relaunch behavior in the installer that we need to add to implement the approach that Smokey suggested.

If the options presented by the "check for updates" code are "Install Now" and "Install on Quit", I'd guess that for the "Install Now" case, restarting wouldn't be that weird. However, if the user chooses "Install on Quit" and later goes to quit NeoOffice, it's likely he or she was done using Neo and would find that Neo being relaunched after installation was a little weird. Sad

I do generally like Oscar's suggestion of installing when quitting instead of when starting; it seems to have a lot fewer drawbacks and tricky scenarios overall (although there's still the crash/force quit case, which I assume would just prompt the user again during the next session), but I think that the relaunch after quit might be too weird. My knowledge of Installer.app (and the Neo-specific scripts in our packages) is pretty limited; is it possible to pass it user-specified parameters on invocation (e.g., relaunch=NO) that get passed to the Neo installer scripts? Alternatively, could Neo itself write a small file to a known location (or add a key to the NSUserDefaults/plist?) when the user chooses installation method, and the Neo installer scripts read that file and, if the file indicates that the user chose "on quit", not invoke the relaunch? Just some thoughts. It's probably not the end of the world, but to me it seems like it would be better to not auto-relaunch in the "on quit" case if possible…

Smokey

_________________
"[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sat Feb 11, 2012 4:04 pm    Post subject:

sardisson wrote:
If the options presented by the "check for updates" code are "Install Now" and "Install on Quit", I'd guess that for the "Install Now" case, restarting wouldn't be that weird. However, if the user chooses "Install on Quit" and later goes to quit NeoOffice, it's likely he or she was done using Neo and would find that Neo being relaunched after installation was a little weird. Sad


I proposed having the following 2 dialogs:

- When the download finishes in the update window, display a dialog with "Install Now", "Install on Quit", and "Cancel" buttons

- If "Install on Quit" was selected, on quit display a "Install updates? Yes or No" dialog.

If they press the "Cancel" button in the first dialog or "No" button in the second dialog, I propose that we don't display any new dialogs on the next run and just wait until the next patch check (normally a week) passes so that we don't pester users that cancel installation.

sardisson wrote:
I do generally like Oscar's suggestion of installing when quitting instead of when starting; it seems to have a lot fewer drawbacks and tricky scenarios overall (although there's still the crash/force quit case, which I assume would just prompt the user again during the next session), but I think that the relaunch after quit might be too weird. My knowledge of Installer.app (and the Neo-specific scripts in our packages) is pretty limited; is it possible to pass it user-specified parameters on invocation (e.g., relaunch=NO) that get passed to the Neo installer scripts? Alternatively, could Neo itself write a small file to a known location (or add a key to the NSUserDefaults/plist?) when the user chooses installation method, and the Neo installer scripts read that file and, if the file indicates that the user chose "on quit", not invoke the relaunch? Just some thoughts. It's probably not the end of the world, but to me it seems like it would be better to not auto-relaunch in the "on quit" case if possible…


You cannot send any data to the Mac OS X installer app in an open document event other than the path to the .pkg directory. However, I think your NSUserDefaults idea should work. Here's the logic I am thinking of using:

1. When the user selects the "Yes" button in the dialog that appears on quitting, we set a new "don't launch after install" user preference and invoke the installer.

2. I add the "defaults" command to the installer ending script that greps for the new preference. I the new preference is there (any value is treated as true), the script skips launching of NeoOffice.

3. Upon next launch of NeoOffice, the new preference is deleted so that NeoOffice reverts the installers to the default behavior of launching NeoOffice.

Do the above proposals sound reasonable?

BTW, I am working on the "install now" case as that gives me a chance to implement all of the tools needed to do an install. So, the discussion about how we want to handle the "install on quit" case won't block development work.

Patrick
Back to top
sardisson
Town Crier
Town Crier


Joined: Feb 01, 2004
Posts: 4588

PostPosted: Sat Feb 11, 2012 9:35 pm    Post subject:

pluby wrote:
- If "Install on Quit" was selected, on quit display a "Install updates? Yes or No" dialog.

If they press the "Cancel" button in the first dialog or "No" button in the second dialog, I propose that we don't display any new dialogs on the next run and just wait until the next patch check (normally a week) passes so that we don't pester users that cancel installation.

Manually accessing the "Check for Updates…" menu item will allow the user to restart/resume this process before the next patch check interval is over, right?

pluby wrote:
Do the above proposals sound reasonable?

BTW, I am working on the "install now" case as that gives me a chance to implement all of the tools needed to do an install. So, the discussion about how we want to handle the "install on quit" case won't block development work.

Everything sounds good Smile

Smokey

_________________
"[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Sun Feb 12, 2012 12:45 am    Post subject:

sardisson wrote:
Manually accessing the "Check for Updates…" menu item will allow the user to restart/resume this process before the next patch check interval is over, right?


Correct.

Patrick
Back to top
ovvldc
Captain Naiobi


Joined: Sep 13, 2004
Posts: 2352
Location: Zürich, CH

PostPosted: Mon Feb 13, 2012 11:54 am    Post subject:

pluby wrote:
For those who have to maintain many Macs, I highly recommend that they look at using Mac OS X's "installer" Terminal command.


I suppose you use the terminal version for the updating then? We've already agreed to licenses and such when we installed NeoOffice the first time, and we've just told NeoOffice that we want to update, so I don't particularly see the need for the UI...

Best wishes,
Oscar

_________________
"What do you think of Western Civilization?"
"I think it would be a good idea!"
- Mohandas Karamchand Gandhi
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Mon Feb 13, 2012 12:04 pm    Post subject:

ovvldc wrote:
pluby wrote:
For those who have to maintain many Macs, I highly recommend that they look at using Mac OS X's "installer" Terminal command.


I suppose you use the terminal version for the updating then? We've already agreed to licenses and such when we installed NeoOffice the first time, and we've just told NeoOffice that we want to update, so I don't particularly see the need for the UI...


No. Our update will run the GUI installer tool as the Terminal version has no UI so if the user presses an "install now" or similar button in NeoOffice, we really should display some UI so that the user knows when the installation is done.

I only mentioned the Terminal installer command for IT staff are trying to automate the installation of system and application updates on many different machines. In such environments, many users do not have administrative privileges on their machines and IT will use custom or commercial tools that run as the root user to install updates to machines in the background.

In contrast, our update process is for users who maintain their own machines so our code will keep as much of the process as visible as possible. After all, users cannot run NeoOffice as the root user so we are already back into GUI mode in order to authenticate themselves to run the installer.

Patrick
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Mon Feb 13, 2012 12:17 pm    Post subject:

pluby wrote:
I only mentioned the Terminal installer command for IT staff are trying to automate the installation of system and application updates on many different machines. In such environments, many users do not have administrative privileges on their machines and IT will use custom or commercial tools that run as the root user to install updates to machines in the background.


I forgot to mention that I have implemented code for the next test patch that will automatically disable patch checking if the user does not have administrative privileges. It always seemed odd to urge people to download an installer only to find that they cannot run the installer because someone has not give the user administrative privileges for their machine.

Patrick
Back to top
sardisson
Town Crier
Town Crier


Joined: Feb 01, 2004
Posts: 4588

PostPosted: Mon Feb 13, 2012 3:03 pm    Post subject:

pluby wrote:
I forgot to mention that I have implemented code for the next test patch that will automatically disable patch checking if the user does not have administrative privileges. It always seemed odd to urge people to download an installer only to find that they cannot run the installer because someone has not give the user administrative privileges for their machine.

Can't users authenticate as an admin user, though, when Installer prompts them?

One of the common "security" recommendations you hear for Mac OS X is to not run your daily activities as an admin user; I can't imagine all these people that do that switch to the other account to download and install updates to every piece of software that needs to authenticate as an admin.

I just checked (with the current test patch and versionrc) with one of my testing user accounts that is a standard account, and Installer prompted me to enter an admin username and password before it started installing files; I entered my admin username and password, and the patch installed successfully.

So I think disabling update checking if the current user is not an admin user could likely break a lot of workflows by never letting users know there are new updates. Sad

Smokey

_________________
"[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
Back to top
djpimley
The Anomaly
(earlier version)


Joined: Jun 11, 2006
Posts: 481
Location: Great Britain

PostPosted: Mon Feb 13, 2012 3:48 pm    Post subject:

sardisson wrote:
So I think disabling update checking if the current user is not an admin user could likely break a lot of workflows by never letting users know there are new updates. Sad

Agreed. I run all my Macs in the configuration you describe and advise my tech-savvy friends to do the same. I keep an eye on the forum so I'm unlikely to miss a patch announcement but the principal remains.
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Mon Feb 13, 2012 4:15 pm    Post subject:

sardisson wrote:
So I think disabling update checking if the current user is not an admin user could likely break a lot of workflows by never letting users know there are new updates. Sad


Since the last 2 posts are 2 votes against disabling patch checking for non-admin users, I will disable this new code. The code was not very sophisticated so not much time was spent implementing the code.

Patrick
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Tue Feb 14, 2012 9:03 pm    Post subject:

FYI. I have uploaded a new test patch that implements nearly all of the functionality that we have discussed adding for this new feature. Below is a list of the specific changes that are in this test patch.

Note: I have not yet implemented Oscar's idea to display a dialog when you quit NeoOffice if you selected the "install later" option when you first downloaded a file but I will include that in the next test patch:

1. Immediately after downloading a file and mounting it using the "hdiutil" command, NeoOffice will display a dialog that asking the user if they want to install now or later. I used the OpenOffice.org code's localizations for the dialog so that this dialog will display as many languages as possible.

2. Pressing the "Install now" button in the above dialog will start the normal application quit process and if the user does not press the Cancel button in any of the normal dialogs that appear, the downloaded installer will be launched in the Mac OS X installer tool.

3. Pressing the "Install later" button will keep the downloaded file in a list in memory so that if you download any other files (like a language pack) and select the "Install now" option after a later install, not only will the last downloaded installer be launched, but the installers that the user chose the "Installer later" option for will also be launched.

4. The "batch launching" described in item 3 above has some a few limitations at this time. First, if the user unmounts the volume sometime between when it was mounted by NeoOffice and before the user finally pressed the "Install now" button, that installer will not be launched. Second, installers are separated into 2 different types: full installers or language pack and patch installers. The installer launching code will launch installers in order of Unicode name sorting (which so far matches our Intel release order) but it will stop launching when the installer type changes or if the first installer in the list is a full installer. The idea here is that language packs and patch installers can be batched even if the Mac OS X installer runs them in a different order than launched, but full installers run out of order will cause their language packs and patches to fail to install.

5. All of the language pack and patch installers that we build after this point in time will launch NeoOffice after they finish installation. In addition, all future installers (including future full installers) will not launch NeoOffice if the "updateSuppressLaunchAfterInstallation" in the org.neooffice.NeoOffice.plist user preference file is set to true. The latest test patch does not yet ever set this preference to true, but it will in when I implement Oscar's proposal in the next test patch.

6. I have added code to detect if our webservers include a special query string parameter in the patch download URL that is returned to NeoOffice. If that query string parameter is in the URL, the old "open the download page in the user's default web browser" behavior is used. I added this code so that if we find that this new patch download tool has serious bugs after we release it in an official patch, we can change one line of code on our webservers and ensure that users can get the next patch that fixes any bugs we find in our download tool. In other words, this code is there to handle failure of the patch download tool.

I think we are getting close to completion of this new feature request but please don't hesitate to tell us if you find any apparent bugs or confusing behavior in the latest test patch.

Like the last test patch, to test out my latest changes you will need to do the following steps:

1. Download and install the following test patch:

Intel:
http://sally.neooffice.org/test/NeoOffice-3.2.1-Patch-3-Test-5-Intel.dmg

2. Download the following "versionrc" file to your Desktop by pasting the following command in a Terminal window and pressing the Return key. This file will be used to fool NeoOffice to act as if you have not installed the latest official patch:

Code:
cd ~/Desktop ; curl -O http://sally.neooffice.org/test/versionrc


3. In the Finder, right-click or Control-click on the NeoOffice application and in the popup menu that appears, select the "Show Package Contents". Then, navigation into NeoOffice's "Contents/MacOS" subfolder. Drag the "versionrc" file that you downloaded into step 2 into this subfolder. You will be prompted to replace the file and then to authenticate that you are a Mac OS X administrator.

4. If step 3 succeeds, select NeoOffice's Help :: Check for Updates menu. the dialog that appears should say that NeoOffice 3.2.1 Patch 3 is available. Press the Download button and you should see the patch download page running in a floating window similar to the NeoOffice Mobile floating window and the patch should be automatically downloaded to your Downloads folder.

Patrick
Back to top
djpimley
The Anomaly
(earlier version)


Joined: Jun 11, 2006
Posts: 481
Location: Great Britain

PostPosted: Wed Feb 15, 2012 1:34 am    Post subject:

I'll test this as soon as I am able, and report the results here.
Back to top
ovvldc
Captain Naiobi


Joined: Sep 13, 2004
Posts: 2352
Location: Zürich, CH

PostPosted: Thu Feb 16, 2012 10:59 am    Post subject:

I have tried it out and found the following:

-When it finds a patch, the option to get it is labelled as 'download manually'.

-When it finishes downloading, and I select 'install later' the window with the download page stays, and the X button at the bottom is grayed out.

-You may need to inform the user that the patch file should be left in the download folder until installed.

Other than that it works as advertised Smile.

_________________
"What do you think of Western Civilization?"
"I think it would be a good idea!"
- Mohandas Karamchand Gandhi
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Thu Feb 16, 2012 11:25 am    Post subject:

ovvldc wrote:
-When it finds a patch, the option to get it is labelled as 'download manually'.


The Download button text is set by the OpenOffice.org localizations so maybe the Dutch localization for that button isn't good. If you have a better Dutch localization, please post it and I can replace the OpenOffice.org localization. However, you won't see your modified localization until the next NeoOffice release because the localizations are installed via the language packs.

There are some localizations that do not use the OpenOffice.org localization code. If you can translate the quoted English phrases in the following list (the first half of the list was already translated by you for NeoOffice Mobile), I can put them in the next test patch:

Code:
UPDATEDOWNLOADCANCELED, "Ophalen geannuleerd",
UPDATEDOWNLOADFAILED, "Ophalen mislukt",
UPDATEDOWNLOADINGFILE, "Bestand ophalen",
UPDATEERROR, "Fout:",
UPDATELOADING, "Laden…",
UPDATEMEGABYTE, "MB",
UPDATEOPENFILEFAILED, "Cannot open %@",
UPDATEOPENINGFILE, "Opening %@…",
UPDATEREDOWNLOADFILE, "Do you want to redownload the file?"


I also need to decide what text to put in the "install at quit" dialog. Here is my current proposed text:

Code:
Do you want to install the updates that you downloaded?


Can anyone suggest better text or translate the above text?

ovvldc wrote:
-When it finishes downloading, and I select 'install later' the window with the download page stays, and the X button at the bottom is grayed out.


I'll fix that in the next test patch. Right now, the "close window" code is only getting invoked if you select the "install now" button.

ovvldc wrote:
You may need to inform the user that the patch file should be left in the download folder until installed.


The .dmg file will be mounted if you see the "install now or later" dialog so even if you drag the .dmg file to the Trash, you will not be able to empty it from the Trash unless you also unmount it. If the user has both unmounted the volume, dragged the .dmg to the Trash, and emptied the Trash, I would assume that they really don't want to install it right now.

Patrick
Back to top
djpimley
The Anomaly
(earlier version)


Joined: Jun 11, 2006
Posts: 481
Location: Great Britain

PostPosted: Thu Feb 16, 2012 1:21 pm    Post subject:

pluby wrote:
I'll fix that in the next test patch. Right now, the "close window" code is only getting invoked if you select the "install now" button.

I think if the download is successful, the download window should disappear before the install dialog appears; the web view no longer serves any purpose and I find that stacked UI elements are distracting to less savvy users.

Incidentally, is that X button ever active? I haven't noticed any moment in the recent tests when it was not ghosted.

pluby wrote:
Do you want to install the updates that you downloaded?

I think that is very good, clear and concise.

ovvldc wrote:
You may need to inform the user that the patch file should be left in the download folder until installed.

I think that kind of message would be over-thinking the design. If the user deletes the patch dmg then it will simply be downloaded again in a future patch check. A warning message is putting a burden of responsibility on the user that - however minor - is not necessary.

Edit: I tested the latest patch and it behaved as expected.
Back to top
Display posts from previous:   
   NeoOffice Forum Index -> NeoOffice New Feature Requests All times are GMT - 7 Hours
Goto page Previous  1, 2, 3, 4, 5  Next
Page 4 of 5

 
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
You cannot attach files in this forum
You cannot download files in this forum

Powered by phpBB © 2001, 2005 phpBB Group

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © Planamesa Inc.
NeoOffice is a registered trademark of Planamesa Inc. and may not be used without permission.
PHP-Nuke Copyright © 2005 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.