Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add some settings for unifying develop environment #187

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
BasedOnStyle: Google
LineEnding: LF
ColumnLimit: 120
# indent
UseTab: Never
IndentWidth: 4
TabWidth: 4

---
## C/C++ style definitions
Language: Cpp

# include
IncludeCategories:
- Regex: '../'

# indent style
IndentPPDirectives: AfterHash


# Brace Position
BreakBeforeBraces: Custom
BraceWrapping:
AfterFunction: true
AfterStruct: true
AfterControlStatement: Never

# Align style
AlignConsecutiveDeclarations: true
AlignTrailingComments: true
AlignArrayOfStructures: Left
AlignConsecutiveMacros: true
AlignOperands: false

72 changes: 72 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
## EditorConfig is awesome: https://EditorConfig.org
#
# @(#) editorconfig settings for c programming
#
# @version 1.0.0
# @date 2024-03-07
# @license GPLv2
#
# @description <<
# user default editorconfig :
# for c programming with GitHub
#
#<<



# top-most EditorConfig file
root = true

# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true

# default character-set
charset = utf-8

# indent style
indent_size = tab
indent_style = tab
tab_width=4

# ext type settings

# script executable
[**.]
indent_style = space
indent_size = 2
tab_width = 2

### Programming language
[**.{c,h}]
indent_style = tab
indent_size = tab
tab_width = 4

# shell script
[**.{sh,bash}]
indent_style = space
indent_size = 2
tab_width = 2

### setting files

# for git config
[**.git*]
indent_style = tab
indent_size = tab
tab_width = 4

[**/git/*]
indent_style = tab
indent_size = tab
tab_width = 4

### document, etc
# markdown
[**.md]
indent_size = tab
tab_width = 2
indent_style = space

40 changes: 40 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# @(#) : git ignore file for c codes
#

Makefile
Makefile.in
aclocal.m4
Expand All @@ -21,3 +24,40 @@ src/rlwrap
stamp-h1
tools/
filters/RlwrapFilter.3pm
**testit.trs

### Generated by gibo (https://github.com/simonwhitaker/gibo)
### https://raw.github.com/github/gitignore/4488915eec0b3a45b5c63ead28f286819c0917de/C++.gitignore

# Prerequisites
*.d

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app