iceberg
iceberg copied to clipboard
Enable option to use local git cache of git repo if there are network issues when trying to connect to remote
When running code like below, if there is no network connection, the code will fail, even if there is a local git copy on the machine.
Metacello new
baseline: 'MyProject';
repository: 'github://myproject';
load.
I've coded workarounds like below, but considering I'm introspecting with instVarNamed: we probably need to expose error codes from libgit a bit more officially
[Metacello new
baseline: 'ABaseline';
repository: 'github://aPath';
load. ]
on: IceGenericError
do: [:anError|
(anError instVarNamed: #wrappedException) object = LGitErrorTypeEnum giterr_net
ifTrue: [
Metacello new
baseline: 'ABaseline';
repository: 'gitlocal://aPath';
load.
]