A Bash tool to fetch and display GitHub user information in JSON format using the GitHub API.
To use the Copilot script, follow these steps:
-
Clone the repository:
git clone https://github.com/haithamaouati/Copilot.git
-
Change to the Copilot directory:
cd Copilot
-
Change the file modes
chmod +x copilot.sh
-
Run the script:
./copilot.sh
./copilot.sh [options]
Examples:
- Fetch user information without authentication:
./copilot.sh -u octocat
- Fetch user information with a personal access token:
./copilot.sh -u octocat -t ghp_12345abcdef
- Save the response to a file:
./copilot.sh -u octocat -f user_data.json
If you frequently use a personal access token, you can preload it by creating a token file in the script's directory. The script will automatically detect and use it:
echo "ghp_12345abcdef" > token
The script requires the following dependencies:
- figlet: Program for making large letters out of ordinary text
- curl: Command line tool for transferring data with URL syntax
- jq: Command-line JSON processor
Make sure to install these dependencies before running the script.
Made with ☕ by Haitham Aouati
- GitHub: github.com/haithamaouati
Copilot is licensed under Unlicense license.