mirror of
https://blitiri.com.ar/repos/chasquid
synced 2025-12-16 14:27:01 +00:00
Auto-format protobuf files
This patch runs clang-format on the protobuf files, and also adds a Makefile target for auto-formatting code (Go and protobuf) for convenience.
This commit is contained in:
4
.clang-format
Normal file
4
.clang-format
Normal file
@@ -0,0 +1,4 @@
|
||||
Language: Proto
|
||||
BasedOnStyle: Google
|
||||
IndentWidth: 8
|
||||
UseTab: AlignWithSpaces
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -6,6 +6,7 @@
|
||||
# Exceptions to the rules above: files we care about that would otherwise be
|
||||
# excluded.
|
||||
!.gitignore
|
||||
!.clang-format
|
||||
!.github/
|
||||
|
||||
# The binaries.
|
||||
|
||||
7
Makefile
7
Makefile
@@ -55,6 +55,11 @@ install-config-skeleton:
|
||||
chown -v mail:mail /var/lib/chasquid ; \
|
||||
fi
|
||||
|
||||
fmt:
|
||||
go vet ./...
|
||||
gofmt -s -w .
|
||||
clang-format -i $(shell find . -iname '*.proto')
|
||||
|
||||
.PHONY: chasquid test \
|
||||
chasquid-util smtp-check mda-lmtp dovecot-auth-cli
|
||||
chasquid-util smtp-check mda-lmtp dovecot-auth-cli \
|
||||
fmt
|
||||
|
||||
@@ -28,7 +28,8 @@ message Config {
|
||||
|
||||
// Addresses to listen on for submission-over-TLS (usually port 465).
|
||||
// Default: "systemd", which means systemd passes sockets to us.
|
||||
// systemd sockets must be named with "FileDescriptorName=submission_tls".
|
||||
// systemd sockets must be named with
|
||||
// "FileDescriptorName=submission_tls".
|
||||
repeated string submission_over_tls_address = 5;
|
||||
|
||||
// Address for the monitoring http server.
|
||||
@@ -37,9 +38,9 @@ message Config {
|
||||
string monitoring_address = 6;
|
||||
|
||||
// Mail delivery agent (MDA, also known as LDA) to use.
|
||||
// This should point to the binary to use to deliver email to local users.
|
||||
// The content of the email will be passed via stdin.
|
||||
// If it exits unsuccessfully, we assume the mail was not delivered.
|
||||
// This should point to the binary to use to deliver email to local
|
||||
// users. The content of the email will be passed via stdin. If it exits
|
||||
// unsuccessfully, we assume the mail was not delivered.
|
||||
// Default: "maildrop".
|
||||
string mail_delivery_agent_bin = 7;
|
||||
|
||||
|
||||
@@ -49,10 +49,9 @@ message Recipient {
|
||||
// We used to use the well-known type, but the dependency makes packaging much
|
||||
// more convoluted and adds very little value, so we now just include it here.
|
||||
message Timestamp {
|
||||
// Represents seconds of UTC time since Unix epoch.
|
||||
int64 seconds = 1;
|
||||
// Represents seconds of UTC time since Unix epoch.
|
||||
int64 seconds = 1;
|
||||
|
||||
// Non-negative fractions of a second at nanosecond resolution.
|
||||
int32 nanos = 2;
|
||||
// Non-negative fractions of a second at nanosecond resolution.
|
||||
int32 nanos = 2;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user