Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Clang-Shebang
- ## Terminal Usage
- ```bash
- $ cp clangshebang.cpp myprogram.cpp
- $ chmod +x myprogram.cpp
- $ ./myprogram.cpp
- hello shell
- ```
- ## Emacs usage
- In Emacs init.el:
- ```elisp
- (global-set-key (kbd "<f5>") #'my/try-build-run-project)
- (global-set-key (kbd "<f7>") #'my/try-build-project)
- ```
- In emacs session, hit `f5`. It will run `myprogram.cpp`.
- ## Projectile Usage
- In terminal:
- ```bash
- $ ./myprogram.cpp --gen-emacs-dirlocals
- ```
- In emacs session, hit `f5`. It will do the right thing.
- If you just want to build, hit `f7`.
- I haven't added `projectile-projectile-test-cmd` yet because I am lazy.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement