[Pharo-users] Iceberg - finding deleted classes, reverting versions?

Ben Coman btc at openinworld.com
Thu Jun 28 07:25:08 EDT 2018


On 28 June 2018 at 07:38, Tim Mackinnon <tim at testit.works> wrote:

> Hey thanks Ben - this still doesn’t work for me… good idea to try on the
> Pharo repo itself.
>
> I have a fork of it, which I catch up periodically - so I tried a similar
> suggestion to you - went into my directory (underneath the src folder) and
> typed:
>
> log --diff-filter=D --summary --graph --pretty='format:%cd | %h | %H |
> %cn%n-> %s%n’
>
> This gave me:
>
> Tue Jun 19 19:28:37 2018 +0200 | 13e81343e | 13e81343e8a23a8d6ca43f1c77b804b8134fc986
> | CyrilFerlicot
> -> Remove now useless logs
>
>  delete mode 100755 bootstrap/scripts/printFolderContent.sh
>
> Mon Jun 18 16:50:19 2018 +0200 | 0433d908d | 0433d908de2987fa0069a47dee1f0794ccbb52c2
> | GitHub
> -> Revert "22161-Add-more-log-to-bootstrap"
>
>  delete mode 100755 bootstrap/scripts/printFolderContent.sh
>
> Thu Jun 14 11:41:16 2018 +0200 | b4a285a61 | b4a285a61d3eb0cc1e642b2fcc242dac7092617f
> | Marcus Denker
> -> fix the last sender of #asIcon https://pharo.fogbugz.com/f/
> cases/22139/fix-the-last-sender-of-asIcon
>
>  delete mode 100644 src/Polymorph-Widgets-Rules/IconShortcutRule.class.st
>
> So then I tried to recover that last one (again at root underneath the src
> directory)
>
> git checkout b4a285a61 src/Polymorph-Widgets-Rules/Ic
> onShortcutRule.class.st
> error: pathspec 'src/Polymorph-Widgets-Rules/IconShortcutRule.class.st'
> did not match any file(s) known to git.
>

Concrete examples help.   I get the same error
when I try checking that file out from b4a285a61

Now looking at
https://github.com/pharo-project/pharo/tree/b4a285a61/src/Polymorph-Widgets-Rules/
there is no file  IconShortcutRule.class.st
<http://iconshortcutrule.class.st/>

So from try clicking the <History> button,
and currently at the top you'll see " b4a28" on Jun 14,
and the next one down is "d4b4464".
Click the "<>" button to the right of that,
then browse back to .../src/Polymorph-Widgets-Rules
and now you'll see  IconShortcutRule.class.st
<http://iconshortcutrule.class.st/>

So the following works for me...
git checkout d4b4464 src/Polymorph-Widgets-Rules/IconShortcutRule.class.st
<http://iconshortcutrule.class.st/>

In summary ;), you can't check out a file from a commit that doesn't exist
in that commit.

HTH
cheers -ben
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pharo.org/pipermail/pharo-users_lists.pharo.org/attachments/20180628/440e62c0/attachment.html>


More information about the Pharo-users mailing list