decimal
Task
decimal | Task | |
---|---|---|
15 | 113 | |
5,945 | 10,055 | |
2.0% | 2.1% | |
7.4 | 9.6 | |
11 days ago | 5 days ago | |
Go | MDX | |
GNU General Public License v3.0 or later | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
decimal
-
Trouble understanding rounding when the next digit is after round precision is a #5?
Try it in JS with console.log(4.225 * 100);, you'll see the same unexpected result. Depending on your needs, it's actually fine to just be off by some amount. If it does really matter, then use an arbitrary precision library like https://github.com/shopspring/decimal to get the results you need.
-
Handling currency values: facts and best practices
Most programming languages ( JavaScript, PHP, Go, Python, Java, C# ) have built-in support or 3rd-party libraries for handling this data type, even though the internal implementations can differ:
-
Any go and python number experts here?
while working with money, dont use floats, use something like https://github.com/shopspring/decimal (go std lib doesnt have its own decimals yet)
-
my first golang project!
Integers, or something like this: https://github.com/shopspring/decimal
-
80x improvements in caching by moving from JSON to gob
I make heavy use of caching, and was caching both in-memory and in Redis using JSON to convert the data in to a string. The struct itself isn't super complicated, one level nested, and some fields use the shopspring/decimal library.
-
Unexported interfaces usage question
I actually use this to represent monetary values btw :)
-
How to round(2) float64?
Check out https://github.com/shopspring/decimal for doing money related calculations.
-
Library recommendation -- money calculations, more accurate handling of floats
We personally use https://github.com/shopspring/decimal and it works well.
-
What are your favorite packages to use?
decimal, one of the first Go library that created to work with decimal and monetary value.
-
What libraries from other languages do you wish were ported over into go?
https://github.com/shopspring/decimal also.
Task
-
Show HN: Workflow Orchestrator in Golang
So many tools in this space! This one looks a little bit like go-task, but it seems maybe better for production workflows because if timeout support, while go-task seems more aimed to command line work/makefile replacement.
—-
https://github.com/go-task/task
-
Essential Command Line Tools for Developers
View on GitHub
- Task: A task runner / alternative to GNU Make
-
Using Make – writing less Makefile
A similar tool is `task` https://taskfile.dev/ . It is quite capable and also a single executable. I've grown to quite like it.
-
What’s with DevOps engineers using `make` of all things?
check out tasks - a bit of a learning curve but arguably more powerful imo
-
Go Development with Hot Reload Using Taskfile
That's when I came across taskfile.dev. Task is an automation tool designed to be more accessible than other options, such as GNU Make.
-
Poetry (Packaging) in motion
Full disclosure, I did not review Conda or Hatch fully. Not that there is anything explicitly wrong with either of them. Conda is too specific to the scientific community for my general taste. Hatch seems to go well with Conda and also uses the PyProject manifest as well. It's nice that it gives you several built in tools, similar to commit hooks, but I tend to like to roll my own via a Taskfile and run them with Poetry.
-
Building RESTful API with Hexagonal Architecture in Go
Taskfile is a tool for streamlining repetitive development tasks. It helps automate activities like building, testing, and deploying applications. Unlike Makefile, Taskfile uses YAML for configuration, making it more readable and user-friendly.
-
We built the fastest CI in the world. It failed
9. We test everything with another promotion which runs make targets which build docker containers to run python scripts (pytest)
This is also built by a complicated web of wildcarded makefile targets, which need to be interoperable and support a few if/else cases for specific components.
My plan is to migrate all of this to something simpler and more straightforward, or at least more maintainable, which is honestly probably going to turn into taskfile[0] instead of makefiles, and then simple python scripts for the glue that ties everything together or does more complex logic.
My hope is that it can be more straightforward and easier to maintain, with more component-ized logic, but realistically every step in that labyrinthine build process (and that's just the open-source version!) came from a decision made by a very talented team of engineers who know far more about the process and the product than I do. At this point I'm wondering if it would make 'more sense' to replace it with a giant python script of some kind and get access to all the logic we need all at once (it would not).
[0] https://taskfile.dev/
-
Exploring GCP With Terraform: Setting Up The Environment And Project
task - a task runner and a replacement for make
What are some alternatives?
Golang Crypto Trading Bot - A golang implementation of a console-based trading bot for cryptocurrency exchanges
just - 🤖 Just a command runner
decimal - A high-performance, arbitrary-precision, floating-point decimal library.
doit - task management & automation tool
go-money - Go implementation of Fowler's Money pattern
goreleaser - Deliver Go binaries as fast and easily as possible
go-finance - :warning: Deprecrated in favor of https://github.com/piquette/finance-go
boilr - :zap: boilerplate template manager that generates files or directories from template repositories
Testify - A toolkit with common assertions and mocks that plays nicely with the standard library
JobRunner - Framework for performing work asynchronously, outside of the request flow
apd - Arbitrary-precision decimals for Go
taskctl - Concurrent task runner, developer's routine tasks automation toolkit. Simple modern alternative to GNU Make 🧰