aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorng0 <ng0@n0.is>2019-04-28 17:53:04 +0000
committerng0 <ng0@n0.is>2019-04-28 17:53:04 +0000
commita907d690368f749aef29d6bc95ec3c3187f96243 (patch)
tree8d8829a61f08c7192d988d8c2451d659b0f1ed81
parent34ca3b497950afdbff25123c02bfc75794214f9f (diff)
downloaddoxygen2mdoc-a907d690368f749aef29d6bc95ec3c3187f96243.tar
doxygen2mdoc-a907d690368f749aef29d6bc95ec3c3187f96243.tar.gz
HACKING, Makefile, add moderately okayish .clang-format file
-rw-r--r--.clang-format123
-rw-r--r--HACKING7
-rw-r--r--Makefile28
3 files changed, 144 insertions, 14 deletions
diff --git a/.clang-format b/.clang-format
new file mode 100644
index 0000000..2389434
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,123 @@
+---
+Language: Cpp
+# BasedOnStyle: LLVM
+AccessModifierOffset: -2
+AlignAfterOpenBracket: Align
+AlignConsecutiveAssignments: false
+AlignConsecutiveDeclarations: false
+AlignEscapedNewlines: Left
+AlignOperands: true
+AlignTrailingComments: false
+AllowAllArgumentsOnNextLine: false
+AllowAllParametersOfDeclarationOnNextLine: false
+AllowShortBlocksOnASingleLine: false
+AllowShortCaseLabelsOnASingleLine: false
+AllowShortFunctionsOnASingleLine: All
+AllowShortIfStatementsOnASingleLine: false
+AllowShortLoopsOnASingleLine: false
+AlwaysBreakAfterDefinitionReturnType: None
+AlwaysBreakAfterReturnType: TopLevel
+AlwaysBreakBeforeMultilineStrings: false
+AlwaysBreakTemplateDeclarations: MultiLine
+BinPackArguments: false
+BinPackParameters: false
+BraceWrapping:
+ AfterClass: false
+ AfterControlStatement: true
+ AfterEnum: true
+ AfterFunction: true
+ AfterNamespace: false
+ AfterObjCDeclaration: false
+ AfterStruct: true
+ AfterUnion: true
+ AfterExternBlock: false
+ BeforeCatch: false
+ BeforeElse: true
+ IndentBraces: false
+ SplitEmptyFunction: true
+ SplitEmptyRecord: true
+ SplitEmptyNamespace: true
+BreakBeforeBinaryOperators: None
+BreakBeforeBraces: Custom
+BreakBeforeInheritanceComma: false
+BreakInheritanceList: BeforeColon
+BreakBeforeTernaryOperators: true
+BreakConstructorInitializersBeforeComma: false
+BreakConstructorInitializers: BeforeColon
+BreakAfterJavaFieldAnnotations: false
+BreakStringLiterals: false
+ColumnLimit: 80
+CommentPragmas: '^ IWYU pragma:'
+CompactNamespaces: false
+ConstructorInitializerAllOnOneLineOrOnePerLine: false
+ConstructorInitializerIndentWidth: 2
+ContinuationIndentWidth: 4
+Cpp11BracedListStyle: true
+DerivePointerAlignment: false
+DisableFormat: false
+ExperimentalAutoDetectBinPacking: true
+FixNamespaceComments: true
+ForEachMacros:
+ - foreach
+ - Q_FOREACH
+ - BOOST_FOREACH
+IncludeBlocks: Preserve
+IncludeCategories:
+ - Regex: '^"(llvm|llvm-c|clang|clang-c)/'
+ Priority: 2
+ - Regex: '^(<|"(gtest|gmock|isl|json)/)'
+ Priority: 3
+ - Regex: '.*'
+ Priority: 1
+IncludeIsMainRegex: '(Test)?$'
+IndentCaseLabels: false
+IndentPPDirectives: None
+IndentWidth: 8
+IndentWrappedFunctionNames: false
+JavaScriptQuotes: Leave
+JavaScriptWrapImports: true
+KeepEmptyLinesAtTheStartOfBlocks: true
+MacroBlockBegin: ''
+MacroBlockEnd: ''
+MaxEmptyLinesToKeep: 2
+NamespaceIndentation: None
+ObjCBinPackProtocolList: Auto
+ObjCBlockIndentWidth: 2
+ObjCSpaceAfterProperty: false
+ObjCSpaceBeforeProtocolList: true
+PenaltyBreakAssignment: 2
+PenaltyBreakBeforeFirstCallParameter: 9999999
+PenaltyBreakComment: 300
+PenaltyBreakFirstLessLess: 120
+PenaltyBreakString: 1000
+PenaltyBreakTemplateDeclaration: 10
+PenaltyExcessCharacter: 1000000
+PenaltyReturnTypeOnItsOwnLine: 60
+PointerAlignment: Right
+ReflowComments: true
+SortIncludes: false
+SortUsingDeclarations: true
+SpaceAfterCStyleCast: true
+SpaceAfterLogicalNot: true
+SpaceAfterTemplateKeyword: true
+SpaceBeforeAssignmentOperators: true
+SpaceBeforeCpp11BracedList: false
+SpaceBeforeCtorInitializerColon: true
+SpaceBeforeInheritanceColon: true
+SpaceBeforeParens: Always
+SpaceBeforeRangeBasedForLoopColon: true
+SpaceInEmptyParentheses: false
+SpacesBeforeTrailingComments: 1
+SpacesInAngles: false
+SpacesInContainerLiterals: true
+SpacesInCStyleCastParentheses: false
+SpacesInParentheses: false
+SpacesInSquareBrackets: false
+Standard: Cpp11
+StatementMacros:
+ - Q_UNUSED
+ - QT_REQUIRE_VERSION
+TabWidth: 8
+UseTab: Always
+...
+
diff --git a/HACKING b/HACKING
new file mode 100644
index 0000000..fecaae3
--- /dev/null
+++ b/HACKING
@@ -0,0 +1,7 @@
+Don't modify:
+
+ * tests.c
+ * configure
+ * compats.c
+
+These files come from a build of oconfigure.
diff --git a/Makefile b/Makefile
index 7a492b4..be4a543 100644
--- a/Makefile
+++ b/Makefile
@@ -2,30 +2,30 @@
include Makefile.configure
-WWWDIR = /var/www/vhosts/kristaps.bsd.lv/htdocs/sqlite2mdoc
-VERSION = 0.1.4
+WWWDIR = /var/www/d.n0.is/pub/doxygen2mdoc
+VERSION = 0.1
DOTAR = Makefile \
compats.c \
main.c \
tests.c \
- sqlite2mdoc.1
+ doxygen2mdoc.1
-all: sqlite2mdoc
+all: doxygen2mdoc
-sqlite2mdoc: main.o compats.o
+doxygen2mdoc: main.o compats.o
$(CC) -o $@ main.o compats.o $(LDFLAGS) $(LDADD)
-www: sqlite2mdoc.tar.gz
+www: doxygen2mdoc.tar.gz
installwww: www
mkdir -p $(WWWDIR)/snapshots
install -m 0444 sqlite2mdoc.tar.gz $(WWWDIR)/snapshots
install -m 0444 sqlite2mdoc.tar.gz $(WWWDIR)/snapshots/sqlite2mdoc-$(VERSION).tar.gz
-sqlite2mdoc.tar.gz:
- mkdir -p .dist/sqlite2mdoc-$(VERSION)/
- install -m 0644 $(DOTAR) .dist/sqlite2mdoc-$(VERSION)
- install -m 0755 configure .dist/sqlite2mdoc-$(VERSION)
+doxygen2mdoc.tar.gz:
+ mkdir -p .dist/doxygen2mdoc-$(VERSION)/
+ install -m 0644 $(DOTAR) .dist/doxygen2mdoc-$(VERSION)
+ install -m 0755 configure .dist/doxygen2mdoc-$(VERSION)
( cd .dist/ && tar zcf ../$@ ./ )
rm -rf .dist/
@@ -33,12 +33,12 @@ main.o: config.h
install:
mkdir -p $(DESTDIR)$(PREFIX)/bin
- mkdir -p $(DESTDIR)$(PREFIX)/man/man1
- install -m 0755 sqlite2mdoc $(DESTDIR)$(PREFIX)/bin
- install -m 0444 sqlite2mdoc.1 $(DESTDIR)$(PREFIX)/man/man1
+ mkdir -p $(DESTDIR)$(PREFIX)/$(MANDIR)/man1
+ install -m 0755 doxygen2mdoc $(DESTDIR)$(PREFIX)/bin
+ install -m 0444 doxygen2mdoc.1 $(DESTDIR)$(PREFIX)/$(MANDIR)/man1
distclean: clean
rm -f config.h config.log Makefile.configure
clean:
- rm -f sqlite2mdoc main.o compats.o sqlite2mdoc.tar.gz
+ rm -f doxygen2mdoc main.o compats.o doxygen2mdoc.tar.gz