c610364b083be709c529edb20488ef1509ce98c6
David Blume Use Markdown in README.md

David Blume authored 9 years ago

README.md   1) # testcode
README.md   2) 
README.md   3) This is just a test project. You can do anything here, test g++, make, cmake,
README.md   4) git, cscope, and IDE projects.
README.md   5) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md   6) ## Getting the project
David Blume Use Markdown in README.md

David Blume authored 9 years ago

README.md   7) 
README.md   8) You can get a copy of this project by clicking on the
dblume Update http to https in REA...

dblume authored 1 year ago

README.md   9) [ZIP](https://git.dlma.com/testcode.git/zipball/main)
README.md  10) or [TAR](https://git.dlma.com/testcode.git/tarball/main) buttons
David Blume Use Markdown in README.md

David Blume authored 9 years ago

README.md  11) near the top right of the GitList web page.
David Blume first commit

David Blume authored 9 years ago

README     12) 
David Blume Update the README

David Blume authored 9 years ago

README     13) You can clone from the origin with:
README     14) 
David Blume Use Markdown in README.md

David Blume authored 9 years ago

README.md  15)     git clone ssh://USERNAME@dlma.com/~/git/testcode.git
David Blume Update the README

David Blume authored 9 years ago

README     16) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  17) ## IDEs
README.md  18) 
README.md  19) ### tmux vim entr
README.md  20) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  21) Create two panes in tmux, run vim in one, and run entr in the other. You probably
README.md  22) only need the `git ls-files` for `entr`, but I provide a bash command group with
README.md  23) `find` here so I can easily copy and change it as needed.
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  24) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  25)     { git ls-files && find . -type f -regex '.*\.\(cfg\|local\)'; } | \
dblume Add --show-leak-kinds=all v...

dblume authored 2 years ago

README.md  26)     entr -c sh -c 'ctags -R *; make -j$(nproc) && \
README.md  27)     valgrind -q --leak-check=yes --show-leak-kinds=all product/testcode'
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  28) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  29) `find` could also have been `find . -type f \( -name \*.cfg -or -name \*.local \)`.
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  30) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  31) To compile with debug info and run in gdb:
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  32) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  33)     ... | entr -c sh -c 'ctags -R *; make debug -j$(nproc) && gdb product/testcode'
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  34) 
dblume Add git ls-files and change...

dblume authored 3 years ago

README.md  35) Tip: In vim you can grep and use the QuickFix window with commands like...
README.md  36) 
README.md  37)     :grep -rI --exclude=tags --exclude=cscope.* --exclude-dir=obj searchterm .
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  38)     :cw
README.md  39) 
dblume Update http to https in REA...

dblume authored 1 year ago

README.md  40) See [this QuickFix tip for sorting results by filename](https://git.dlma.com/dotfiles.git/commit/0cb566c53caf931c8b3f423dcfded4660b220cbb).
David Blume Mention the vim QuickFix to...

David Blume authored 3 years ago

README.md  41) 
dblume Add entr one-liner for when...

dblume authored 3 years ago

README.md  42) #### entr One-Liner for When no Makefile
README.md  43) 
README.md  44) [This entr command is handy](https://twitter.com/dblume/status/1421011043489255424) when composing interview questions without a Makefile:
README.md  45) 
dblume Add --show-leak-kinds=all v...

dblume authored 2 years ago

README.md  46)     ls -1 *.h *.cpp | entr sh -c 'g++ -Wall -std=c++17 -pthread *.cpp && \
README.md  47)     valgrind -q --leak-check=yes --show-leak-kinds=all ./a.out'
dblume Add entr one-liner for when...

dblume authored 3 years ago

README.md  48) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md  49) ### Visual Studio Code and WSL2
README.md  50) 
README.md  51) Once you've got the [Remote -WSL extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-wsl)
README.md  52) for WSL, you can invoke Code from the WSL side.
README.md  53) 
README.md  54)     code .
README.md  55) 
README.md  56) Or, if it's not in your path, something like...
README.md  57) 
README.md  58)     /mnt/c/Users/$USER/AppData/Local/Programs/Microsoft\ VS\ Code/bin/code .
README.md  59) 
dblume Restore the IDEs section

dblume authored 1 year ago

README.md  60) ### Other IDEs
README.md  61) 
README.md  62) Look for the presence of their project files. They should work normally.
dblume Add .clang-format

dblume authored 1 year ago

README.md  63) 
dblume Restore the IDEs section

dblume authored 1 year ago

README.md  64) ## Formatting
dblume Add .clang-format

dblume authored 1 year ago

README.md  65) 
dblume Added instructions for newe...

dblume authored 1 year ago

README.md  66) Use clang-format. Install the distro's version with:
dblume Add .clang-format

dblume authored 1 year ago

README.md  67) 
README.md  68)     sudo apt install clang-format
README.md  69) 
dblume Prefer pipx install clang-f...

dblume authored 11 months ago

README.md  70) Or install a newer one with:
dblume Added instructions for newe...

dblume authored 1 year ago

README.md  71) 
dblume Prefer pipx install clang-f...

dblume authored 11 months ago

README.md  72)     pipx install clang-format
README.md  73) 
README.md  74) And move $HOME/.local/bin ahead of /usr/bin in your $PATH.
dblume Added instructions for newe...

dblume authored 1 year ago

README.md  75) 
dblume Mention git-clang-format

dblume authored 1 year ago

README.md  76) Then, after making your edits, use the [vim integration](https://clang.llvm.org/docs/ClangFormat.html#vim-integration)
README.md  77) or manually format in one of a couple of ways:
README.md  78) 
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  79) ### Option 1: Use git clang-format to format your staged changes
README.md  80) 
README.md  81) **NOTE** git-clang-format only formats your changes. Often it's better to
README.md  82) always format the whole document.
dblume Mention git-clang-format

dblume authored 1 year ago

README.md  83) 
README.md  84) `git-clang-format` is installed with clang-format and will format staged files
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  85) into the unstaged area. Use it like this:
dblume Mention git-clang-format

dblume authored 1 year ago

README.md  86) 
README.md  87) 1. Stage the files you want to format.
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  88) 2. Run `git clang-format`, and it'll leave unstaged formatting changes.
dblume Mention git-clang-format

dblume authored 1 year ago

README.md  89) 3. Review with `git difftool` and accept the desired changes or unstage.
README.md  90) 
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  91) ### Option 2: Manually clang-format the staged files
README.md  92) 
README.md  93) The following formats the staged files, not only your staged changes:
dblume Add .clang-format

dblume authored 1 year ago

README.md  94) 
README.md  95)     git status --porcelain | \
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  96)     awk '/^[MTARC].+\.([hc](pp)?)"?$/ {$1=""; $0=$0; $1=$1; print}' | \
README.md  97)     xargs clang-format -i
dblume Add .clang-format

dblume authored 1 year ago

README.md  98) 
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md  99) Or a similar approach but it'll also overwrite your unstaged changes too:
dblume Add .clang-format

dblume authored 1 year ago

README.md 100) 
dblume Distinguish "git clang-form...

dblume authored 1 month ago

README.md 101)     git ls-files -m | \
README.md 102)     grep -E ".[ch](pp)?$" | tr "\n" "\0" | \
README.md 103)     xargs -0 clang-format -i
dblume Add .clang-format

dblume authored 1 year ago

README.md 104) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md 105) ## Current Features
David Blume first commit

David Blume authored 9 years ago

README    106) 
README    107) * Multiple directories for testing build systems and IDEs
README    108) * "make" essentially works.
README    109) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md 110) ## Is it any good?
David Blume Use Markdown in README.md

David Blume authored 9 years ago

README.md 111) 
README.md 112) [Yes](https://news.ycombinator.com/item?id=3067434).
README.md 113) 
David Blume Added some documentation fo...

David Blume authored 3 years ago

README.md 114) ## To Do
David Blume first commit

David Blume authored 9 years ago

README    115) 
README    116) * Compare make vs. cmake vs. autotools
David Blume Update the README

David Blume authored 9 years ago

README    117) * Experiment with ctags generation