diff options
author | katherine <ageha@airen-no-jikken.icu> | 2022-06-17 07:02:05 -0700 |
---|---|---|
committer | katherine <ageha@airen-no-jikken.icu> | 2022-06-17 07:02:05 -0700 |
commit | 128ee73027aaa230c30a838d6eda10be757aeb75 (patch) | |
tree | 7e22cbc9525a1194da3e647009d5058b6df2b4dc /.ocamlinit | |
parent | 12217a6d3b9f3cc16188554da31485b76ad23df2 (diff) | |
download | dotfiles-128ee73027aaa230c30a838d6eda10be757aeb75.tar.gz |
adapt utop to new Core / Core_unix split
Diffstat (limited to '.ocamlinit')
-rw-r--r-- | .ocamlinit | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -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 "┌["; |