-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #4: registerStonesDirectory.solo added, tested and validated
- Loading branch information
1 parent
73a7057
commit e9a918d
Showing
5 changed files
with
72 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
#!/usr/bin/env superdoit_solo | ||
options | ||
{ | ||
SuperDoitRequiredOptionWithRequiredArg long: 'registry'. | ||
SuperDoitRequiredOptionWithRequiredArg long: 'stonesDirectory'. | ||
} | ||
% | ||
Usage | ||
----- | ||
USAGE $basename [--help | -h] [--debug | -D] [--debugGem] \ | ||
--registry=<registry-name> --stonesDirectory=<path-to-stones-directory> | ||
|
||
DESCRIPTION | ||
Register a stones directory for the named registry. If the directory does not | ||
exist the directory is created. The stones directory is used as the default location | ||
to create a named stone. | ||
|
||
OPTIONS | ||
-h, --help display usage message | ||
-D, --debug bring up topaz debugger in the event of a script error | ||
--debugGem If terminal is connected to stdout, bring up debugger. If not, | ||
dump stack to stdout and wait for topaz to attach using topaz | ||
DEBUGGEM command. | ||
|
||
EXAMPLES | ||
$basename --help | ||
$basename -D | ||
$basename --registry=bosch -stonesDirectory=/home/dhenrich/gemstone/stones | ||
----- | ||
% | ||
specs | ||
[ | ||
RwLoadSpecificationV2 { | ||
#projectName : 'GsDevKit_stones', | ||
#projectSpecFile : 'rowan/project.ston', | ||
#componentNames : [ | ||
'Core', | ||
'Solo' | ||
], | ||
#platformProperties : { | ||
'gemstone' : { | ||
'allusers' : { | ||
#defaultSymbolDictName : 'Globals' | ||
} | ||
} | ||
}, | ||
#comment : '' | ||
} | ||
] | ||
% | ||
doit | ||
| registryClass stonesRegistry stonesDir stonesDirPath | | ||
self preDoitSpecLoad: [:spec | | ||
spec projectsHome: self dirname asFileReference parent parent]. | ||
registryClass := (self globalNamed: 'GDKRegistry'). | ||
stonesRegistry := registryClass stonesRegistryNamed: self registry. | ||
stonesDir := self stonesDirectory asFileReference. | ||
stonesDir ensureCreateDirectory. | ||
stonesDirPath := GsFile serverRealPath: stonesDir pathString. | ||
stonesRegistry stonesDirectory: stonesDirPath. | ||
stonesRegistry export. | ||
|
||
% |
3 changes: 3 additions & 0 deletions
3
src/GsDevKit_stones-Core.package/GDKStonesRegistry.class/instance/stonesDirectory..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
accessing | ||
stonesDirectory: object | ||
stonesDirectory := object |
3 changes: 3 additions & 0 deletions
3
src/GsDevKit_stones-Core.package/GDKStonesRegistry.class/instance/stonesDirectory.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
accessing | ||
stonesDirectory | ||
^stonesDirectory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters