Newbiemacs Homepage
Table of Contents
Home
Newbiemacs character by Artist Ujoo
Introduction
Main features of Newbiemacs
- Organize your pdf and tex files.
- Search pdf and tex files quickly.
- Easy to use.
- You can play the torus game!
Installation
macOS
- Install Emacs version 28.2. Click here to download an installation file.
- Install Git. Click here to download an installation file.
Open a terminal and enter the following lines. (You can open a terminal by pressing Command+Space and typing "terminal". You can just copy the whole thing and then paste it in your terminal.)
cd ~ git clone https://github.com/jangsookim/newbiemacs.git nbm-root cp ~/nbm-root/.emacs ~/.emacs
- Run Emacs. It will take several minutes to download necessary packages. There may be some warnings but it's okay. When it's done, there will be a message at the bottom saying "For information about GNU Emacs and the GNU system, type C-h C-a."
- Close Emacs and run it again. The Newbiemacs main screen will be shown.
Additional steps for latex on macOS (optional)
If you want to edit tex files in Newbiemacs, you need to do the following (only once).
- Install Skim and MacTeX (this is TeX Live for macOS).
- Open Skim and press
CMD+,
(Hold the command key and press the comma key.) - Go to the
Sync
menu and check the two check boxes. - Select Emacs in the drop-down box for
Preset
.- If this doesn't work try the following in skim option.
- Select Preset: custom and enter the full path in the command field, e.g.
/opt/homebrew/bin/emacsclient
or/Applications/Emacs.app/Contents/MacOS/bin-arm64-11/emacsclient
. - Arguments should the the same things for Emacs, i.e.
--no-wait +%line "%file"
.
Windows
- Install Emacs version 28.2. Click here to download an installation file.
- Install Git. Click here to download an installation file.
- Install Perl.
Open "Command Prompt" (not "terminal" or "PowerShell") and enter the following lines. (You can just copy the whole thing and then paste it in your command prompt.)
cd "%userprofile%" git clone https://github.com/jangsookim/newbiemacs.git nbm-root copy "%userprofile%\nbm-root\.emacs-windows" "%userprofile%\AppData\Roaming\.emacs"
- Run Emacs. It will take several minutes to download necessary packages. There may be some warnings but it's okay. When it's done, there will be a message at the bottom saying "For information about GNU Emacs and the GNU system, type C-h C-a."
- Close Emacs and run it again. It will take some more time but eventually the Newbiemacs main screen will be shown.
Additional steps for latex on Windows (optional)
If you want to use latex in Newbiemacs, you need to do the following (only once).
- Install TeX Live. Click here (It may take about 2 hours.)
- Install Sumatra PDF. Click here (Download "Installer", not "Portable version".)
- Open Sumatra PDF and in the menu go to
Settings
and clickOptions...
. Enter the following line in the box below
Set inverse search command-line
.C:\Program Files\Emacs\emacs-28.2\bin\emacsclientw.exe -n +%l "%f"
If the box is not visible, then in the menu go to
Settings
and clickAdvanced Options...
. It will open a text file. Enter the following line anywhere there and save the file.InverseSearchCmdLine = C:\Program Files\Emacs\emacs-28.2\bin\emacsclientw.exe -n +%l "%f"
GNU/Linux
- Install Emacs version 28.1 or later (Install "GNU Emacs" using "Ubuntu Software" if you installed Ubuntu).
Install necessary packages.
sudo apt install gcc git
Open a terminal and enter the following lines.
cd ~ git clone https://github.com/jangsookim/newbiemacs.git nbm-root cp ~/nbm-root/.emacs ~/.emacs
- Run Emacs. It will take several minutes to download necessary packages. There may be some warnings but it's okay. When it's done, there will be a message at the bottom saying "For information about GNU Emacs and the GNU system, type C-h C-a."
- Close Emacs and run it again. The Newbiemacs main screen will be shown.
Additional steps for latex on GNU/Linux (optional)
If you want to edit tex files in Newbiemacs, you need to do the following (only once).
Install necessary packages.
sudo apt install texlive-full wmctrl
Tutorial
Introduction
- In this tutorial you will learn how to use Newbiemacs.
- You can use the basic features of Newbiemacs in the following Newbiemacs screen. (To go to the Newbiemacs screen, type
ALT-BACKSPACE
. In macOS,ALT
is the command key.)
- By default your Newbiemacs folder will be
~/newbiemacs
(~
means your home folder.) - The current file name is shown at the bottom of the Newbiemacs screen.
- Type
F
in the Newbiemacs screen to open the folder containing the current file. - Newbiemacs provides three editing styles, Vim, Emacs, and Windows (default). To change the editing style, type
e
in the Newbiemacs screen. - You can view the Newbiemacs cheat sheet by typing
?
in the Newbiemacs screen.
Overview
- In this tutorial we learn how to manage pdf, tex, and miscellaneous files.
- We will also see some useful tools: adding a figure, changing variables, and converting latex code to HWP math code (for Korean only).
- The basic concept of managing files is to store these files in their directories and search them.
- The directories for these files are under the newbiemacs folder.
- To open the newbiemacs folder, type
ALT-BACKSPACE
twice and then typeF
- The pdf, tex, and miscellaneous files will be stored in the
pdf
,tex
, andmisc
folders under the newbiemacs folder. - You may manually move your files into one of these folders.
How to find a pdf, tex, or miscellaneous file
- Finding a file is very easy.
- Type
p
,t
, ors
in the Newbiemacs screen to find a pdf, tex, or miscellaneous file. - Type anything that you can remember about the file name.
- It will list all files with the key words that you have entered there.
- Choose the file that you want to open and press the enter key.
Add new files
- Note that it is important to have a good file name scheme so that we can search files easily.
- The following methods will do this effortelessly.
How to add a pdf file from arxiv
- Download the pdf file of a paper from https://arxiv.org/ (You must download it into your download folder instead of just viewing it on your browser.)
Copy the two lines of the title and the authors like this:
- Go to your Emacs with the Newbiemacs main screen.
- Type
m
and follow the instructions at the bottom of the Emacs screen. - It will save a pdf with name scheme such as "Author 1, Authur 2, Title".
- Now you can search the pdf by typing
p
in on the Newbiemacs main screen.
How to add a pdf file of a published paper
- Download a pdf file into your download folder.
- Go to MathSciNet or zbMATH (zbMATH is free).
Search the paper there. You will see something like this
Click the drop-down box at the top left corner and select bibtex.
Copy the bibtex item.
- Go to your Emacs with the Newbiemacs main screen.
- Type
m
and follow the instructions at the bottom of the Emacs screen. - It will save a pdf with name scheme such as "Author 1, Authur 2, Year, Title".
- Now you can search the pdf by typing
p
in on the Newbiemacs main screen. - It will also ask if you want to create a bib item for this paper.
How to create a new tex file
- Type
n
in the Newbiemacs screen. - Enter a file name for the new tex file. (The extension
.tex
is not needed. This name will also be the title inside the tex file.) - Choose a template file. (For the default, just hit the enter key.)
- Now you can search the tex file by typing
t
in on the Newbiemacs main screen.
Symlinks
- A symlink is a link to a file similar to a "shortcut" to a file.
- Creating a symlink will allow you to search a file without moving it
to one of the
pdf
,tex
,misc
folders.
How to create a symlink to a file
- Go to the Newbiemacs screen.
- In your Finder or File Explorer, find a file that you want to create a symlink.
- Drag-and-drop the file into the Newbiemacs screen.
- Type
ALT-BACKSPACE
, which will bring you back to the Newbiemacs screen. - Type
S
. Then it will ask you to enter a symlink name. Follow the instructions. - On macOS, a symlink will be created in this way and you are done.
- On Windows, however, it will only copy a string in the clipboard. Now open the command prompt run as administrator. Paste the string in the command prompt.
Some useful tools
- Even if you don't use Newbiemacs for editing tex files, you may find the following tools useful.
Add a figure in a tex file
- Using Newbiemacs you can add an image into your tex file as follows.
- Take a screenshot (or upload a screenshot from your tablet).
- Go to your tex file.
- Press
ALT-BACKSPACE
to go to the Newbiemacs main screen. - Press
f
and follow the instructions.
- By default Newbiemacs will search the downloads folder and the desktop.
- If your computer saves screenshots in a different folder you can add
the folder: type
ALT-BACKSPACE
followed byx
followed by3
, and add the directory path in a new line.
Change variables
- While writing your paper, you realized that you want to change the variable
i
toj
. - You cannot simply replace all
i
toj
, because then it will also change a word likethis
tothjs
and a macro like\int
to\jnt
. - In Newbiemacs you can do the variable change as follows.
- Open your tex file.
- If you want the change only on some part, select the region by dragging your mouse. (If you want the change in the entire file, you don't have to do this.)
- Press
ALT-BACKSPACE
to go to the Newbiemacs main screen. - Press
v
and follow the instructions.
Convert latex code to HWP math code (for Korean)
Suppose that you want to use the following latex code in Hangul program (한글 프로그램).
\sum_{i=1}^n \frac{a_i}{b_i} = \prod_{i=1}^n c_i^2
- You can convert this latex code to HWP math code as follows.
- Select the latex code by dragging your mouse (without
$
or\( \)
or\[ \]
). - Press
ALT-BACKSPACE
to go to the Newbiemacs main screen. Press
h
and a converted HWP math code will be stored in the clipboard. For example, the above latex code will be converted tosum_{ i=1}^n {a_i }over{b_i } = prod_{ i=1}^n c_i^2
- Go to Hangul program and paste the clipboard string in the math
input window (
ctrl n m
)
- Select the latex code by dragging your mouse (without
Manual
For more details, click the Newbiemacs manual.
FAQ
How can I open the Newbiemacs directory?
- Type
ALT-BACKSPACE
twice and then typeF
How can I update Newbiemacs?
- Type
U
in the Newbiemacs screen. (You may need to restart Emacs.)
How can I change the newbiemacs folder?
- Close Emacs and move the newbiemacs folder as you wish.
- Open
~/nbm-root/nbm-home.txt
(This is the file containing the path to the Newbiemacs folder.) - Update the old path with the new path.
- Start Emacs.
How can I use a spell-checker?
Check the section on "Spell checking" in the Newbiemacs manual.
How can change fontsize globally?
Add the following line in your
user-init.el
and change the number150
as you want. (To openuser-init.el
, typeSPC N c u
.)(set-face-attribute 'default nil :height 150)
How can I re-install Newbiemacs?
You can re-installing Newbiemacs keeping your Newbiemacs folder
~/newbiemacs
. It will take much less than the actual installation.
- Delete the folder
~/nbm-root
(For macOS or GNU/Linux) Enter the following in a terminal.
cd ~ git clone https://github.com/jangsookim/newbiemacs.git nbm-root
(For Windows) Enter the following in Command Prompt.
cd %userprofile% git clone https://github.com/jangsookim/newbiemacs.git nbm-root
Troubleshooting
Newbiemacs crashed! What should I do?
- Restart Newbiemacs.
- If it's still not working, re-install Newbiemacs.
I cannot compile bibtex.
- If there is a space in the path of your newbiemacs folder, you cannot compile bibtex.
- It is strongly recommended that you change your newbiemacs folder so that it has no space.
If you need to use icloud, whose path is
/Users/<username>/Library/Mobile Documents/com~apple~CloudDocs
, you need to run the following in your terminal. (You have to change<username>
with your actual username.)ln -s "/Users/<username>/Library/Mobile Documents" "/Users/<username>/Library/Mobile-Documents"
Torus Leader Board
rank | name | score | level | date |
---|---|---|---|---|
1 | jia | 576900 | 17 | 2023/02/28 |
2 | jjh | 459600 | 15 | 2023/03/25 |
3 | U-keun | 382200 | 13 | 2023/02/21 |
4 | jangsoo | 329700 | 13 | 2023/02/13 |