Skip to content

animesh/scripts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
Sorry, we had to truncate this directory to 1,000 files. 166 entries were omitted from the list.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

git reset HEAD~

#dockerImage:

docker.io/animesh1977/scripts

#ignore MS/DOS endings (on windows machines):

git config --global core.autocrlf true

#aliases

rebase

beflog

stash

log --graph

bisect

merge

push --force-with-lease

#config setup

cd scripts

ln -s $PWD/config.bash $HOME/.bashrc

!. *.pdf *.asv *.csv *.txt *.history *swp *gz *tsv

Auto Login and Form Submission Script

This script uses Selenium to automatically log in to a website and submit a form using credentials and data from environment variables.

Requirements

  • Python 3.x
  • Google Chrome browser
  • ChromeDriver (matching your Chrome version)
  • selenium Python package

Setup

  1. Install dependencies:

    pip install -r requirements.txt
  2. Download ChromeDriver:

  3. Set environment variables:

    • LOGIN_URL: The URL of the login page.
    • LOGIN_USERNAME: Your username.
    • LOGIN_PASSWORD: Your password.
    • FORM_FIELD_1: Data for the form field (example; add more as needed).
    • CHROMEDRIVER_PATH: (Optional) Path to your chromedriver binary.

    Example (Linux/macOS):

    export LOGIN_URL='https://example.com/login'
    export LOGIN_USERNAME='your_username'
    export LOGIN_PASSWORD='your_password'
    export FORM_FIELD_1='your_form_data'
    export CHROMEDRIVER_PATH='/path/to/chromedriver'

Usage

Run the script:

python auto_login_form.py

Customization

  • Update the field selectors in auto_login_form.py to match the actual names or XPaths of the login and form fields on your target website.
  • Add more environment variables and form fields as needed.

Notes

  • The script runs Chrome in headless mode by default.
  • For troubleshooting, remove the --headless option to see the browser window.

About

Miscellaneous scripts moved from https://code.google.com/p/misccb/

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •