-
Notifications
You must be signed in to change notification settings - Fork 0
feat: initial implementation of go-tlog with examples, CI and README #1
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
base: master
Are you sure you want to change the base?
Conversation
Initial project setup: - Added logger core (level, format, stacktrace, internal outputs) - Added tests for core logger functionality - Added examples (stdout, stderr, file) - Added GitHub Actions CI workflow - Added README and LICENSE (BSD 2-Clause) - Added .golangci.yml and .gitignore
d2eb898 to
6e31ef2
Compare
_examples/file/main.go
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is better to make testable examples in Golang: https://go.dev/blog/examples
- This is an idiomatic approach.
- The examples will be showed in the documentation.
README.md
Outdated
| [Telegram EN](https://t.me/tarantool) • | ||
| [Telegram RU](https://t.me/tarantoolru) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some budgets are without images that looks bad. You could copy-paste approach from here:
148dbe1 to
6c9e010
Compare
6c9e010 to
21269a5
Compare
| branches: [ '**' ] | ||
| workflow_dispatch: | ||
|
|
||
| jobs: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need a linter job too. See go-discovery/go-storage/go-tarantool etc.
|
|
||
| func (o *Outputs) Write(p []byte) (int, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A comment is missed.
|
|
||
| func (b *buffer) Free() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The same about comment to public calls: missed.
| // Copyright 2022 The Go Authors. All rights reserved. | ||
| // Use of this source code is governed by a BSD-style | ||
| // license that can be found in the LICENSE file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use a correct copyright and mention the Go authors in the project's LICENSE file if so.
Makefile
Outdated
| ## Run all _examples to ensure they compile and run without panic | ||
| examples: | ||
| $(GO) run ./_examples/stdout | ||
| $(GO) run ./_examples/stderr >/dev/null 2>&1 || true | ||
| $(GO) run ./_examples/file | ||
| $(GO) run ./_examples/multi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| ## Run all _examples to ensure they compile and run without panic | |
| examples: | |
| $(GO) run ./_examples/stdout | |
| $(GO) run ./_examples/stderr >/dev/null 2>&1 || true | |
| $(GO) run ./_examples/file | |
| $(GO) run ./_examples/multi |
Co-authored-by: Oleg Jukovec <[email protected]>
Co-authored-by: Oleg Jukovec <[email protected]>
Co-authored-by: Oleg Jukovec <[email protected]>
7d9aa41 to
38470df
Compare
38470df to
c67ec38
Compare
Added