]> gitweb.factorcode.org Git - factor.git/commitdiff
Revert "use tilde paths in more places."
authorJohn Benediktsson <mrjbq7@gmail.com>
Sat, 18 Jun 2022 23:50:54 +0000 (16:50 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sat, 18 Jun 2022 23:50:54 +0000 (16:50 -0700)
This reverts commit 844060a7d003ae6921f113aceadae67209275455.

basis/editors/visual-studio-code/visual-studio-code.factor
basis/tools/scaffold/scaffold.factor
extra/cpu/8080/emulator/emulator.factor
extra/io/files/acls/macosx/macosx-tests.factor
extra/mason/config/config.factor
extra/mason/release/sign/sign.factor
extra/webapps/mason/backend/backend.factor
extra/websites/concatenative/concatenative.factor

index 867a3c42e6204782e1658ece00392178830dc37b..3cd1267f4c03931138109727ec241b0457dd3798 100644 (file)
@@ -19,7 +19,7 @@ M: visual-studio-code find-visual-studio-code-path
             {
                 [ "code" which ]
                 [ "Code" which ]
-                [ "~/VSCode-linux-x64/Code" ]
+                [ home "VSCode-linux-x64/Code" append-path ]
                 [ "/usr/share/code/code" ]
             } [ dup file-exists? [ drop f ] unless ] map-compose 0|| ] }
         { macosx [
index 5575c5b4174758fa5aaa6fa12f707da3413d8a9f..779214939f751c4c3dc3a30e20a0a5b7e4dbe5f4 100644 (file)
@@ -373,7 +373,7 @@ ${example-indent}}
     [ "Click to edit: " write <pathname> . ] bi ;
 
 : scaffold-rc ( path -- )
-    home prepend-path scaffold-file ;
+    [ home ] dip append-path scaffold-file ;
 
 : scaffold-factor-boot-rc ( -- )
     ".factor-boot-rc" scaffold-rc ;
index b2744af4b9bcc5f215b634cc479acd7432cbb358..7f6eaa62f6c922aaa3def287da6d352b45a5c643 100644 (file)
@@ -453,7 +453,7 @@ SYMBOL: rom-root
 
 : rom-dir ( -- string )
     rom-root get [
-        "~/roms" dup file-exists? [ drop f ] unless
+        home "roms" append-path dup file-exists? [ drop f ] unless
     ] unless* ;
 
 : load-rom* ( seq cpu -- )
index 9a65acb364741915b1874c13fe4ffcb0927c9708..e3942e2b6f76dceb98ad16af6c679c54c95ab564 100644 (file)
@@ -4,4 +4,4 @@ USING: io.files.acls.macosx io.pathnames system tools.test ;
 IN: io.files.acls.macosx.tests
 
 { } [ vm-path acls. ] unit-test
-{ } [ "~/Pictures" acls. ] unit-test
+{ } [ home "Pictures" append-path acls. ] unit-test
index e7bb839f0c11cd6b081ede8b56afa89b15d6eec3..ba6c934bcdbfd3059d45c632631d4a4123454122 100644 (file)
@@ -6,7 +6,9 @@ IN: mason.config
 ! (Optional) Location for build directories
 SYMBOL: builds-dir
 
-builds-dir [ "~/builds" ] initialize
+builds-dir get-global [
+    home "builds" append-path builds-dir set-global
+] unless
 
 ! Who sends build report e-mails.
 SYMBOL: builder-from
@@ -17,12 +19,12 @@ SYMBOL: builder-recipients
 ! (Optional) CPU architecture to build for.
 SYMBOL: target-cpu
 
-target-cpu [ cpu ] initialize
+target-cpu get-global [ cpu target-cpu set-global ] unless
 
 ! (Optional) OS to build for.
 SYMBOL: target-os
 
-target-os [ os ] initialize
+target-os get-global [ os target-os set-global ] unless
 
 ! (Optional) Architecture variant suffix.
 SYMBOL: target-variant
index 0b8c78552f6267e5a6d132bcb73a8df0bbda63d9..8c3c357be67b6cb218da1d41f83d846fd27839bb 100644 (file)
@@ -19,9 +19,11 @@ HOOK: cert-path os ( -- path/f )
 
 M: object cert-path f ;
 
-M: macosx cert-path "~/config/mac_app.cer" ;
+M: macosx cert-path
+    home "config/mac_app.cer" append-path ;
 
-M: windows cert-path "~/config/FactorSPC.pfx" ;
+M: windows cert-path
+    home "config/FactorSPC.pfx" append-path ;
 >>
 
 HOOK: sign-factor-app os ( -- )
index bc19b63d323a5d9ef2168c8ca2c7ab7285987adf..54aed9433edc4be9b95bd983b2ed2a31ed0c83e3 100644 (file)
@@ -82,7 +82,7 @@ counter "COUNTER" {
 : os/cpu ( builder -- string )
     [ os>> ] [ cpu>> ] bi "/" glue ;
 
-: mason-db ( -- db ) "~/mason.db" <sqlite-db> ;
+: mason-db ( -- db ) home "mason.db" append-path <sqlite-db> ;
 
 : with-mason-db ( quot -- )
     mason-db [ with-transaction ] with-db ; inline
index 21f6a26d02e18ce5fd416eb972e82b42ef425eb4..0fa74c49497fe811ed9f63ca1352893bbb8e8891 100644 (file)
@@ -31,7 +31,7 @@ webapps.mason.backend.watchdog
 websites.factorcode ;
 IN: websites.concatenative
 
-: website-db ( -- db ) "~/website.db" <sqlite-db> ;
+: website-db ( -- db ) home "website.db" append-path <sqlite-db> ;
 
 : init-factor-db ( -- )
     mason-db [ init-mason-db ] with-db
@@ -128,10 +128,10 @@ M: cgit call-responder*
         <pastebin> <factor-recaptcha> <login-config> <factor-boilerplate> website-db <alloy> "paste.factorcode.org" add-responder
         <planet> <login-config> <factor-boilerplate> website-db <alloy> "planet.factorcode.org" add-responder
         <mason-app> <login-config> <factor-boilerplate> website-db <alloy> "builds.factorcode.org" add-responder
-        "~/docs" <help-webapp> "docs.factorcode.org" add-responder
-        "~/gitweb" <gitweb> "gitweb.factorcode.org" add-responder
+        home "docs" append-path <help-webapp> "docs.factorcode.org" add-responder
+        home "gitweb" append-path <gitweb> "gitweb.factorcode.org" add-responder
         "/usr/share/cgit" "/usr/lib/cgit/cgit.cgi" <cgit> "cgit.factorcode.org" add-responder
-        "~/irclogs" <static> t >>allow-listings "irclogs.factorcode.org" add-responder
+        home "irclogs" append-path <static> t >>allow-listings "irclogs.factorcode.org" add-responder
     main-responder set-global ;
 
 : <factor-secure-config> ( -- config )