so-notify – A Stack Overflow Question Notifier.

Full Article :

KernalDev - https://www.kerneldev.com/2017/12/27/so-notify-a-stack-overflow-question-notifier/

About Stack Overflow:

Stackoverflow.com is the largest programming related QnA portal. It has over 4,000,000 registered users and over 10,000,000 questions and is the best place to find solutions for your coding related problems. Stack Overflow also has a reputation system which can be earned by answering questions correctly or even by asking good questions. A high reputation count comes in handy when you want to put a bounty on a question which has not received quality answers and let’s be honest, it feels good to see that rep count rise every day!. However earning reputation is not easy due to the fierce competition in the community due to which answers are usually posted within minutes of a question going live!

so-notify – A Stack Overflow Question Notifier

so-notify is a command line application I built which sends a notification to user’s system whenever a new question is posted on stackoverflow.com .

Installation:

Download the latest version of so-notify (v1.0.7) from the Download section of project’s GitHub releases page, extract it and set proper execution privileges.

$gzip -d ./so-notify.gz

$chmod u+x ./so-notify

To be able to run the application from any directory. Move the application to /usr/local/bin

$sudo mv ./so-notify  /usr/local/bin

 

Usage:

  1. View available commands and options:
    $so-notify
  2. Subscribe to a tag:
    $so-notify tag:add  <tag_name>
  3. Show all subscribed tags:
    $so-notify tag:show
  4. Un-subscribe from a tag:
    $so-notify tag:remove <tag_id>
  5. Finally check for questions:
    $so-notify run
  6. Setup a cronjob to check for new questions every minute:
    $crontab -e

    and then append this line to to cron jobs list:

    * * * * * /usr/local/bin/so-notify run
  7. You may need to start/restart your cron service:
    $sudo service cron start

     

Video demo:

Troubleshooting:

  • If you get a Could not connect to the database  error then you might have to install  php and php-sqlite packages and then enable pdo_sqlite extension in your php.ini.

The spirit of open-source! 

This project is fully open-source I welcome your pull requests to the project’s GitHub page and I look forward to hearing your thoughts in the comments section below!!

The post so-notify – A Stack Overflow Question Notifier. appeared first on KernelDev.

Leave a Comment

%d bloggers like this: