crypto_tracker 0.1.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +68 -8
- data/lib/crypto_tracker/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 78515fc411b6c2fc2c62dc1a2e30ff74dabac45157359b6c38b3176eb1e9c718
|
4
|
+
data.tar.gz: f83936b17d891936e6e9b4914dd803522cfc4249c6eef6674744d9e0f707d2f1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cd9f0993b01ed45d07c997fe9b568cc3656651e5be58dedc4a852471c05d1c10d5a6366f39a9d498e2bb5def23d6ffc20d333652cbf989893805ae697ef5c6f7
|
7
|
+
data.tar.gz: e473ba74eca3eed00f8266fd870d8572ca740207598d75afa8a31ac4da589e5bff30f6217cbcb632b73f51024ac9d220049c3e3b9df9a4f3bbf78bfcdbb1a72c
|
data/README.md
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# CryptoTracker
|
2
|
-
CryptoTracker é uma gem Ruby que permite consultar o preço atual e o histórico de preços de qualquer criptomoeda suportada pela API CoinGecko. Os valores podem ser retornados em reais (BRL) ou dólares (USD).
|
2
|
+
CryptoTracker é uma gem Ruby que permite consultar o preço atual e o histórico de preços de qualquer criptomoeda suportada pela API CoinGecko. Os valores podem ser retornados em reais (BRL) ou dólares (USD). A gem também está disponível no [RubyGems](https://rubygems.org/gems/crypto_tracker).
|
3
3
|
|
4
4
|
## 📌 Funcionalidades
|
5
5
|
- Obtenha o preço atual de qualquer criptomoeda;
|
@@ -13,7 +13,7 @@ CryptoTracker é uma gem Ruby que permite consultar o preço atual e o históric
|
|
13
13
|
- CoinGecko API como fonte de dados.
|
14
14
|
|
15
15
|
## 📦 Instalação
|
16
|
-
|
16
|
+
Você pode instalá-la adicionando ao seu Gemfile:
|
17
17
|
```ruby
|
18
18
|
# Gemfile
|
19
19
|
gem 'crypto_tracker'
|
@@ -83,8 +83,8 @@ irb -I lib -r "crypto_tracker"
|
|
83
83
|
|
84
84
|
E teste os métodos:
|
85
85
|
```bash
|
86
|
-
CryptoTracker.price("bitcoin", "usd")
|
87
|
-
CryptoTracker.history("ethereum", 7, "brl")
|
86
|
+
CryptoTracker.price("bitcoin", "usd") # Preço atual do Bitcoin em USD
|
87
|
+
CryptoTracker.history("ethereum", 7, "brl") # Histórico do bitcoin nos últimos 7 dias em BRL
|
88
88
|
```
|
89
89
|
|
90
90
|
Você também pode usar alguns alias do `Makefile` para testes no IRB ou Rails Console:
|
@@ -94,8 +94,68 @@ Você também pode usar alguns alias do `Makefile` para testes no IRB ou Rails C
|
|
94
94
|
| make install | instala a gem localmente |
|
95
95
|
| make uninstall | desinstala a gem localmente |
|
96
96
|
|
97
|
-
##
|
98
|
-
|
97
|
+
## 🤝 Como Contribuir
|
98
|
+
Contribuições são bem-vindas! Para contribuir com a gem crypto_tracker, siga estas etapas:
|
99
|
+
|
100
|
+
### 1️⃣ Fork o Repositório
|
101
|
+
Primeiro, crie um fork do projeto e clone para a sua máquina:
|
102
|
+
```bash
|
103
|
+
git clone https://github.com/seu-usuario/crypto_tracker.git
|
104
|
+
cd crypto_tracker
|
105
|
+
bundle install
|
106
|
+
```
|
107
|
+
|
108
|
+
### 2️⃣ Criar uma Branch para sua Feature/Fix
|
109
|
+
Crie uma nova branch para sua contribuição:
|
110
|
+
```bash
|
111
|
+
git checkout -b minha-nova-feature
|
112
|
+
```
|
113
|
+
|
114
|
+
### 3️⃣ Faça as Modificações e Teste
|
115
|
+
1. Faça as alterações necessárias no código.
|
116
|
+
2. Teste as mudanças para garantir que tudo funciona:
|
117
|
+
|
118
|
+
```bash
|
119
|
+
bundle exec rspec
|
120
|
+
bundle exec rubocop
|
121
|
+
```
|
122
|
+
|
123
|
+
### 4️⃣ Envie um Pull Request
|
124
|
+
1. Faça o commit das mudanças:
|
125
|
+
|
126
|
+
```bash
|
127
|
+
git add .
|
128
|
+
git commit -m "feat: adds new feature X"
|
129
|
+
```
|
130
|
+
|
131
|
+
2. Envie para o seu fork:
|
132
|
+
```bash
|
133
|
+
git push origin minha-nova-feature
|
134
|
+
```
|
135
|
+
|
136
|
+
3. Abra um Pull Request (PR) no repositório oficial.
|
99
137
|
|
100
|
-
##
|
101
|
-
Se você
|
138
|
+
## 💎 Criando uma Nova Versão da Gem
|
139
|
+
Se você estiver publicando uma nova versão da gem, siga estes passos:
|
140
|
+
|
141
|
+
### 1️⃣ Atualizar a Versão
|
142
|
+
Edite o arquivo lib/crypto_tracker/version.rb e modifique a versão, por exemplo:
|
143
|
+
```ruby
|
144
|
+
module CryptoTracker
|
145
|
+
VERSION = "0.2.1"
|
146
|
+
end
|
147
|
+
```
|
148
|
+
|
149
|
+
### 2️⃣ Criar a Tag e Publicar
|
150
|
+
```bash
|
151
|
+
git add lib/crypto_tracker/version.rb
|
152
|
+
git commit -m "Bump version to 0.2.1"
|
153
|
+
git tag -a v0.2.1 -m "v0.2.1"
|
154
|
+
git push origin v0.2.1
|
155
|
+
```
|
156
|
+
🚀 Isso acionará o GitHub Actions para publicar automaticamente a nova versão no [RubyGems](https://rubygems.org/gems/crypto_tracker)! 🎉
|
157
|
+
|
158
|
+
Se você encontrar bugs ou quiser sugerir melhorias, sinta-se à vontade para abrir um Issue ou enviar um Pull Request. 😊
|
159
|
+
|
160
|
+
## 📜 Licença
|
161
|
+
Este projeto está licenciado sob a MIT License - veja o arquivo [LICENSE](https://github.com/davide-almeida/crypto_tracker/blob/main/LICENSE.txt) para mais detalhes.
|