SmalltalkImage>>#imageName
After a brief IRC chat, it seems like returning just the file base (i.e. without the extension). Any objections before I open an issue? SeanDeNigris_: I found it surprising that `Smalltalk imageName` returns the full path. Just me? [11:34am] maxleske: ++ [11:43am] SeanDeNigris_: Worth an issue? Only sender seems to be Spotter [11:49am] DamienCassou: all these little things are annoying. So, +1 to create an issue ----- Cheers, Sean -- View this message in context: http://forum.world.st/SmalltalkImage-imageName-tp4821681.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
+1
Only sender seems to be Spotter Its quite useful for startup scripts.
On Fri, Apr 24, 2015 at 6:23 PM, Sean P. DeNigris <sean@clipperadams.com> wrote:
After a brief IRC chat, it seems like returning just the file base (i.e. without the extension). Any objections before I open an issue?
SeanDeNigris_: I found it surprising that `Smalltalk imageName` returns the full path. Just me? [11:34am] maxleske: ++ [11:43am] SeanDeNigris_: Worth an issue? Only sender seems to be Spotter [11:49am] DamienCassou: all these little things are annoying. So, +1 to create an issue
----- Cheers, Sean -- View this message in context: http://forum.world.st/SmalltalkImage-imageName-tp4821681.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Peter Uhnák wrote
Only sender seems to be Spotter Its quite useful for startup scripts.
Yes, but we have #imageFile fullName already... ----- Cheers, Sean -- View this message in context: http://forum.world.st/SmalltalkImage-imageName-tp4821681p4821692.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
2015-04-24 19:26 GMT+02:00 Sean P. DeNigris <sean@clipperadams.com>:
Peter Uhnák wrote
Only sender seems to be Spotter Its quite useful for startup scripts.
Yes, but we have #imageFile fullName already...
And there is FileLocator image resolve
----- Cheers, Sean -- View this message in context: http://forum.world.st/SmalltalkImage-imageName-tp4821681p4821692.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
On Sat, Apr 25, 2015 at 12:23 AM, Sean P. DeNigris <sean@clipperadams.com> wrote:
After a brief IRC chat, it seems like returning just the file base (i.e. without the extension). Any objections before I open an issue?
SeanDeNigris_: I found it surprising that `Smalltalk imageName` returns the full path. Just me? [11:34am] maxleske: ++ [11:43am] SeanDeNigris_: Worth an issue? Only sender seems to be Spotter [11:49am] DamienCassou: all these little things are annoying. So, +1 to create an issue
+1. We have... Smalltalk>>imageName "Answer the full path name for the current image." ^ FilePathEncoder decode: self primImageName "<primitive: 121>" Smalltalk>>imagePath "Answer the full path name for the current image." ^ FilePathEncoder decode: self primImagePath "<primitive: 121>" ...same duplicate comment, same duplicate result. cheers -ben
Given that there is consensus, I created: Issue 15399 SmalltalkImage>>#imageName is redundant But, thinking more deeply, maybe the cleaner approach would be to remove it completely. Since #imageFile returns a FS object, one already has easy access to whatever variant of the name one wants: #fullName #basename #base Why pollute the protocol? I don't think it's worth it to save from `imageFile base` to `imageName`... And this would apply to #changesName as well... ----- Cheers, Sean -- View this message in context: http://forum.world.st/SmalltalkImage-imageName-tp4821681p4821788.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
participants (4)
-
Ben Coman -
Nicolai Hess -
Peter Uhnák -
Sean P. DeNigris