aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkatherine <ageha@airen-no-jikken.icu>2022-06-17 07:02:05 -0700
committerkatherine <ageha@airen-no-jikken.icu>2022-06-17 07:02:05 -0700
commit128ee73027aaa230c30a838d6eda10be757aeb75 (patch)
tree7e22cbc9525a1194da3e647009d5058b6df2b4dc
parent12217a6d3b9f3cc16188554da31485b76ad23df2 (diff)
downloaddotfiles-128ee73027aaa230c30a838d6eda10be757aeb75.tar.gz
adapt utop to new Core / Core_unix split
-rw-r--r--.ocamlinit9
1 files changed, 5 insertions, 4 deletions
diff --git a/.ocamlinit b/.ocamlinit
index 76ad6c0..f03d1c6 100644
--- a/.ocamlinit
+++ b/.ocamlinit
@@ -2,22 +2,23 @@
#thread;;
#require "core";;
+#require "core_unix";;
open Core;;
#require "lambda-term";;
-let path = Sys.getcwd () in
-let home = Sys.home_directory () in
+let path = Core_unix.getcwd () in
+let home = Sys.getenv_exn "HOME" in
let path =
if Zed_utf8.starts_with path home then
Zed_utf8.replace path 0 (Zed_utf8.length home) "~"
else
path
in
-let user = Unix.getlogin () in
+let user = Core_unix.getlogin () in
let version = Sys.ocaml_version in
-let host = Unix.gethostname () in
+let host = Core_unix.gethostname () in
let formatted = LTerm_text.eval
[B_bold true;
B_fg (LTerm_style.white); S "┌[";