Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/svileng/month
Elixir library focused on working with months, rather than full dates or dates with time.
https://github.com/svileng/month
Last synced: about 1 month ago
JSON representation
Elixir library focused on working with months, rather than full dates or dates with time.
- Host: GitHub
- URL: https://github.com/svileng/month
- Owner: svileng
- License: mit
- Created: 2019-03-21T17:50:15.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-08-08T09:08:19.000Z (over 1 year ago)
- Last Synced: 2024-03-14T20:05:16.038Z (10 months ago)
- Language: Elixir
- Size: 16.6 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Month [![hex.pm](https://img.shields.io/hexpm/v/month.svg?style=flat-square)](https://hex.pm/packages/month) [![hexdocs.pm](https://img.shields.io/badge/docs-latest-green.svg?style=flat-square)](https://hexdocs.pm/month)
Library focused on working with months, rather than full dates or dates with time.
## Installation
[Available in Hex](https://hex.pm/docs/publish), the package can be installed
by adding `month` to your list of dependencies:```elixir
def deps do
[
{:month, "~> 2.0"}
]
end
```## Usage
Full documentation is published here: [https://hexdocs.pm/month](https://hexdocs.pm/month).
However, here is a small sample:
```ex
iex> import Month.Sigils
Month.Sigilsiex> Month.utc_now!()
~M[2019-03]iex> ~M[2019-03].month
3iex> ~M[2019-03].year
2019iex> range = Month.Range.new!(~M[2019-01], ~M[2019-03])
#Month.Range<~M[2019-01], ~M[2019-03]>iex> range.months
[~M[2019-01], ~M[2019-02], ~M[2019-03]]
```## About
This project is sponsored by [Heresy](http://heresy.io). We're always looking for great engineers to join our team, so if you love Elixir, open source and enjoy some challenge, drop us a line and say hello!
## License
- Month: See LICENSE file.
- "Heresy" name and logo: Copyright © 2019 Heresy Software Ltd