issues
search
u413-284-si
/
webserv
This project is about setting up a http web server, providing a static website.
MIT License
0
stars
0
forks
source link
12 devx setup development environment
#13
Closed
gwolf-011235
closed
3 months ago
gwolf-011235
commented
3 months ago
Add some files for project setup
dev container
Adds devcontainer.json and associated Dockerfile which can be used with VS Code extension "Dev Containers".
Container is based on the C++ development example.
Added dependencies:
clang-format: formatting
clang-tidy: static analysis of code
cppcheck: also static analysis
doxygen: generate documentation out of doxygen comments
libgtest-dev: package of google test
clangd: language server as alternative to IntelliSense
bear: used to create compile_commands.json
Setup google test by building library (not automatically done by package)
clang-format
Adds .clang-format file which standardizes formatting
Based on WebKit style
Special config at end of file:
ColumnLimit: 120 (Standard: 0). If Limit is at 0 formatting of comments does not work properly
TabWidth: 4 (Standard: 8). Seems to be more familiar, 8 is too much
UseTab: Always (Standard: Never). Use tabs instead of spaces. We discussed it and agreed that tabs are more modern than spaces
Can be used by executable clang-format to format single files
VSCode can also be set up to use it > Open Settings (UI) > search for Formatting > Under C/C++ configure
clang-tidy
Adds clang-tidy file which enables checks used for static analysis
Enables all checks, then disables project specific one, and some not possible ones (eg C11 features)
Also adds little configs for readability checks. E.g member variables have to use m_
At the end comment describing why checks are disabled (inline comments are not yet supported by our clang-tidy version)
various
Add .cache/ (produced by clangd) and compile_commands.json (used by clangd) to gitignore
Closes #12
Add some files for project setup
dev container
clang-format
clang-tidy
various
Closes #12