Python Script 4: Opening top 10 Google search result in one hit

This is the fourth script in ‘Python Scripts’ series. You can have a look at previous scripts by following the links given below.

Python Script 3: Validate and format JSON string
Python Script 2: Crawling all emails from a website
Python Script 1: Convert ebook from one format to another

As the title suggest, this script is used to open top 10 Google search results in different tabs for provided keyword.

Code:
 

I am using this same concept at my work. Every day I have to open 8 applications (slack, JIRA, gitlab, Facebook :p, stackoverflow, Jenkins UI, Outlook and Personal Email) in my browser. So instead of opening each application one by one, I just run the script and all these applications are opened in different tabs saving few seconds :D.

 

 

How to create completely automated telegram channel with python

In this article we will see how to create a completely automated telegram channel. To demonstrate the process we will take through the example of a telegram channel News India (https://t.me/newsindiachannel) created by me which post news every hour.

The automated process of generating content and posting on the channel is divided into three parts. Creating telegram channel and bot, generating/fetching content using python script and posting the content to telegram channel.

Creating telegram channel and Bot:

-Install telegram app from Google Play.
-After you are done with initial setup. Click on menu and create a new channel.

Continue reading “How to create completely automated telegram channel with python”

Automatically updating Django website hosted on PythonAnyWhere server with every git push

Until now this is how I use to develop and deploy (update) code on PythonAnyWhere server.

  1. Make changes in code on my local machine.
  2. Commit and push the code to remote repository.
  3. Login to PythonAnyWhere server and start bash terminal.
  4. Pull the code from remote repository.
  5. Reload the web app from web tab.

Steps 3 to 5 are time consuming, repetitive and boring. So I thought of eliminating these steps.

In this article we will see how can you get rid of these steps and your web site is automatically updated with the code as soon as you push it to remote repository.

Continue reading “Automatically updating Django website hosted on PythonAnyWhere server with every git push”