tools.deploy.macosx: make deployment work when we're not running the .app bundle
parent
f790934768
commit
929a2d5169
|
@ -1,4 +1,4 @@
|
||||||
! Copyright (C) 2007, 2009 Slava Pestov.
|
! Copyright (C) 2007, 2010 Slava Pestov.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: io io.files io.files.info.unix io.pathnames
|
USING: io io.files io.files.info.unix io.pathnames
|
||||||
io.directories io.directories.hierarchy kernel namespaces make
|
io.directories io.directories.hierarchy kernel namespaces make
|
||||||
|
@ -10,7 +10,10 @@ combinators vocabs.metadata vocabs.loader ;
|
||||||
IN: tools.deploy.macosx
|
IN: tools.deploy.macosx
|
||||||
|
|
||||||
: bundle-dir ( -- dir )
|
: bundle-dir ( -- dir )
|
||||||
vm parent-directory parent-directory ;
|
running.app?
|
||||||
|
[ vm parent-directory parent-directory ]
|
||||||
|
[ "resource:Factor.app" ]
|
||||||
|
if ;
|
||||||
|
|
||||||
: copy-bundle-dir ( bundle-name dir -- )
|
: copy-bundle-dir ( bundle-name dir -- )
|
||||||
[ bundle-dir prepend-path swap ] keep
|
[ bundle-dir prepend-path swap ] keep
|
||||||
|
@ -70,7 +73,6 @@ IN: tools.deploy.macosx
|
||||||
-> selectFile:inFileViewerRootedAtPath: drop ;
|
-> selectFile:inFileViewerRootedAtPath: drop ;
|
||||||
|
|
||||||
M: macosx deploy* ( vocab -- )
|
M: macosx deploy* ( vocab -- )
|
||||||
".app deploy tool" assert.app
|
|
||||||
"resource:" [
|
"resource:" [
|
||||||
dup deploy-config [
|
dup deploy-config [
|
||||||
bundle-name dup exists? [ delete-tree ] [ drop ] if
|
bundle-name dup exists? [ delete-tree ] [ drop ] if
|
||||||
|
|
Loading…
Reference in New Issue