ClangFormat beautifier for Unibeautify
npm install --global @unibeautify/beautifier-clang-format
See unibeautify-cli
for details.
Clang-Format beautifier for Unibeautify
Home Page: https://clang.llvm.org/docs/ClangFormatStyleOptions.html
License: MIT License
ClangFormat beautifier for Unibeautify
npm install --global @unibeautify/beautifier-clang-format
See unibeautify-cli
for details.
There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.
Error type: Cannot find preset's package (github>whitesource/merge-confidence:beta)
clang-format can also format Protocol Buffer definition files but it's not currently included in the languages list in src/index.ts
.
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
These problems occurred while renovating this repository. View logs.
Warning
These dependencies are deprecated:
Datasource | Name | Replacement PR? |
---|---|---|
npm | @types/cosmiconfig |
|
npm | npm-run-all |
|
npm | read-pkg-up |
|
npm | tslint |
|
npm | tslint-microsoft-contrib |
These updates are currently rate-limited. Click on a checkbox below to force their creation now.
These updates have all been created already. Click a checkbox below to force a retry/rebase of any.
tmp
, @types/tmp
)node
, @types/node
)@types/jest
, jest
, ts-jest
).node-version
node v9.10.1
package.json
cosmiconfig ^5.0.5
read-pkg-up ^7.0.0
tmp 0.1.0
@types/jest 24.9.1
@types/cosmiconfig 5.0.3
@types/node 12.20.55
@types/tmp 0.1.0
jest 24.9.0
npm-run-all 4.1.5
rimraf 3.0.2
ts-jest 24.3.0
tslint 5.20.1
tslint-clean-code 0.2.10
tslint-microsoft-contrib 6.2.0
typescript 3.9.10
unibeautify 0.17.1
unibeautify >= 0.15.0
.travis.yml
node 8
node 10
Time to implement the actual clang-format executable beautifier into this.
With the current version from NPM (@unibeautify/[email protected]
), the external program clang-format
gets its settings from a file named .clang-format
in the current directory, just as it does when it runs standalone.
I think .unibeautifyrc
is also ignored altogether. I did a quick test with a .unibeautifyrc
in the same directory as test.c
(an example file to format) and it ignored .unibeautifyrc
even when there is no .clang-format
file in the directory.
This code: https://github.com/Unibeautify/beautifier-clang-format/blob/master/src/index.ts#L136
seems to fallback to -style=file
as a default. I believe we should never use -style=file
or .clang-format
with Unibeautify - @Glavin001 I recall you talked about this in some GitHub issue under some project, giving reasons?
EDIT: Just to recap, here's the -style=
part of clang-format --help
:
-style=<string> - Coding style, currently supports:
LLVM, Google, Chromium, Mozilla, WebKit.
Use -style=file to load style configuration from
.clang-format file located in one of the parent
directories of the source file (or current
directory for stdin).
Use -style="{key: value, ...}" to set specific
parameters, e.g.:
-style="{BasedOnStyle: llvm, IndentWidth: 8}"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.