Created
May 13, 2024 21:22
-
-
Save dincosman/2fa5e918bd531257900812ed0d35c9d0 to your computer and use it in GitHub Desktop.
Install SDKMAN, Java, Node, NVM (Node Version Manager), fast-csv, mongoose and fs npm packages on Macbook M1 Apple Silicon.
This file contains hidden or 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
| --- Install SDKMAN | |
| osmandinc@192 ~ % curl -s "https://get.sdkman.io" | bash | |
| osmandinc@192 ~ % source "/Users/osmandinc/.sdkman/bin/sdkman-init.sh" | |
| osmandinc@192 ~ % sdk version | |
| ... | |
| SDKMAN! | |
| script: 5.18.2 | |
| native: 0.4.6 | |
| -- Install Java | |
| osmandinc@192 ~ % sdk install java 21.0.1-zulu | |
| osmandinc@192 ~ % sdk use java 21.0.1-zulu | |
| -- Clone repo and prepare data | |
| osmandinc@192 ~ % cd Downloads/1brc-main | |
| osmandinc@192 1brc-main % ./mvnw clean verify | |
| [INFO] ------------------------------------------------------------------------ | |
| [INFO] BUILD SUCCESS | |
| [INFO] ------------------------------------------------------------------------ | |
| [INFO] Total time: 01:02 min | |
| [INFO] Finished at: 2024-05-02T21:24:11+03:00 | |
| [INFO] ------------------------------------------------------------------------ | |
| osmandinc@192 1brc-main % ./create_measurements.sh 1000000 | |
| osmandinc@192 1brc-main % ls -lsth measurements.txt | |
| 26952 -rw-r--r-- 1 osmandinc staff 13M May 2 21:25 measurements.txt | |
| osmandinc@192 mongoapi % brew install node | |
| osmandinc@192 mongoapi % brew install nvm | |
| osmandinc@192 ~ % node --version | |
| v22.0.0 | |
| osmandinc@192 ~ % mkdir ~/.nvm | |
| osmandinc@192 ~ % vi .zprofile | |
| export NVM_DIR="$HOME/.nvm" | |
| # This loads nvm | |
| [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" | |
| # This loads nvm bash_completion | |
| [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" | |
| osmandinc@192 ~ % npm i -S fast-csv | |
| osmandinc@192 ~ % npm i -S fs | |
| osmandinc@192 ~ % npm i -S path | |
| osmandinc@192 ~ % npm i -S moongose | |
| osmandinc@192 ~ % npm i -S dotenv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment