๐๐๐๐๐๐
Download and process Brazilian companies' financial data directly from CVM web server:
http://dados.cvm.gov.br/dados/CIA_ABERTA/DOC/DFP/
![License](https://img.shields.io/badge/license-MIT-blue.svg)
Commands
Download and store financial data into the local database
./rapina get
It downloads all files from CVM web server, parses their contents and stores on a sqlite database at .data/rapina.db
.
This command must be run at least once before you run the report
.
List all companies
./rapina list
Create a spreadsheet with a company financial data
./rapina report [flags] company_name
Options
-d, --outputDir string Output directory
-s, --scriptMode Does not show companies list; uses the most similar
company name [default: ./reports]
On Linux or macOS, use the arrow keys to navigate through the companies list. On Windows, use j and k.
Examples
./rapina report WEG
The spreadsheet will be saved at ./reports
./rapina report "TEC TOY" -s -d /tmp/output
The spreadsheet will be saved at /tmp/output
How to compile
- Clone this repo to your PC (
git clone https://github.com/dude333/rapina
)
- Change to CLI directory (
cd rapina/cli
)
- Compile using the Makefile (
make
). To cross compile for Windows on Linux, use make win
.
Contributing
- Fork it
- Download your fork to your PC (
git clone https://github.com/your_username/rapina && cd rapina
)
- Create your feature branch (
git checkout -b my-new-feature
)
- Make changes and add them (
git add .
)
- Commit your changes (
git commit -m 'Add some feature'
)
- Push to the branch (
git push origin my-new-feature
)
- Create new pull request
License
MIT