The Trunk: System-tfel.917.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: System-tfel.917.mcz

commits-2
Tim Felgentreff uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-tfel.917.mcz

==================== Summary ====================

Name: System-tfel.917
Author: tfel
Time: 27 September 2016, 2:52:54.264629 pm
UUID: 6436c2ff-4a02-d845-9b8e-45b8130a609c
Ancestors: System-bf.916

when trying to load a project from my local server when that is not set, at least try to fall back to the default directory

=============== Diff against System-bf.916 ===============

Item was changed:
  ----- Method: Project>>fromMyServerLoad: (in category 'file in/out') -----
  fromMyServerLoad: otherProjectName
  | pair pr dirToUse |
  "If a newer version of me is on the server, load it."
 
  (pr := Project named: otherProjectName) ifNotNil: ["it appeared"
  ^ pr enter
  ].
+
  dirToUse := self primaryServerIfNil: [
+ lastDirectory
+ ifNil: [FileDirectory default]
+ ifNotNil: [lastDirectory]].
- lastDirectory ifNil: [
- self inform: 'Current project does not know a server either.'.
- ^nil].
- lastDirectory].
 
  pair := self class mostRecent: otherProjectName onServer: dirToUse.
  pair first ifNil: [^self decideAboutCreatingBlank: otherProjectName]. "nothing to load"
  ^ProjectLoading
  installRemoteNamed: pair first
  from: dirToUse
  named: otherProjectName
  in: self
 
  !


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: System-tfel.917.mcz

Levente Uzonyi
On Tue, 27 Sep 2016, [hidden email] wrote:

> Tim Felgentreff uploaded a new version of System to project The Trunk:
> http://source.squeak.org/trunk/System-tfel.917.mcz
>
> ==================== Summary ====================
>
> Name: System-tfel.917
> Author: tfel
> Time: 27 September 2016, 2:52:54.264629 pm
> UUID: 6436c2ff-4a02-d845-9b8e-45b8130a609c
> Ancestors: System-bf.916
>
> when trying to load a project from my local server when that is not set, at least try to fall back to the default directory
>
> =============== Diff against System-bf.916 ===============
>
> Item was changed:
>  ----- Method: Project>>fromMyServerLoad: (in category 'file in/out') -----
>  fromMyServerLoad: otherProjectName
>   | pair pr dirToUse |
>   "If a newer version of me is on the server, load it."
>
>   (pr := Project named: otherProjectName) ifNotNil: ["it appeared"
>   ^ pr enter
>   ].
> +
>   dirToUse := self primaryServerIfNil: [
> + lastDirectory
> + ifNil: [FileDirectory default]
> + ifNotNil: [lastDirectory]].

The #ifNotNil: branch is unnecessary.

Levente

> - lastDirectory ifNil: [
> - self inform: 'Current project does not know a server either.'.
> - ^nil].
> - lastDirectory].
>
>   pair := self class mostRecent: otherProjectName onServer: dirToUse.
>   pair first ifNil: [^self decideAboutCreatingBlank: otherProjectName]. "nothing to load"
>   ^ProjectLoading
>   installRemoteNamed: pair first
>   from: dirToUse
>   named: otherProjectName
>   in: self
>
>  !
>
>
>