This tool is used to query the discussion posts of the Condor Info repository. It can provide the maintainer's post as well as index the comments and denote which is marked as an answer.
git clone https://github.com/casper-network/condor-discussions-indexer
cd condor-discussions-indexer
npm installCreate a Personal Access Token through GitHub, providing access only to read:discussion.
Create a new .env file:
touch .envPaste in your new Personal Access Token:
nano .envExample:
GITHUB_PAT=ghp_sgaSFSjBzf7ltXqWj6Y87ljFRgrOyt0ziIYy
First, create a file usernames.txt in the project root:
touch usernames.txtand populate it with one user to track per line:
Example:
dylanireland
sczembor
melpadden
The output will only consist of the users listed in the usernames.txt file.
Get a discussion post by providing the discussion number:
npm run get-discussion 19The script will create a CSV file named discussions_{DISCUSSION_NUMBER}.csv containing each comment as a row of data.