Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Little Python script to open a list of URLs from a file in browser tabs, n tabs at a time
#! /usr/bin/python3
import webbrowser, sys
if len(sys.argv) < 3:
print("Usage: ./urls.txt 20")
f = open(sys.argv[1])
tabs = int(sys.argv[2])
counter = 1
for url in f:
counter += 1
if counter == tabs:
input("Press any key to continue...")
counter = 1

This comment has been minimized.

Copy link

@mtsvnc mtsvnc commented Mar 26, 2020

Nice, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.