Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@rec3141
Created February 9, 2018 10:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rec3141/24090e42b4487635e8ac9f5c566ff417 to your computer and use it in GitHub Desktop.
Save rec3141/24090e42b4487635e8ac9f5c566ff417 to your computer and use it in GitHub Desktop.
get a bibtext file from a text reference list
while read line; do curl -s "https ://api.crossref.org/works?query=`echo $line | tr -sC '[^a-zA-Z]' '+'`" | tr "," "\n" | tr -d '"\' | grep ^DOI | cut -f2- -d':' | head -n1 | xargs -I{} curl -sLH "Accept: application/x-bibtex" https ://doi.org/{} | grep -v '^\s*[<"]'; done < file
@rec3141
Copy link
Author

rec3141 commented Feb 9, 2018

do this in javascript in chrome to scrape the titles of the open tabs using the console tab

journals have meta tags

  |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | <title>Impact of Haida Eddies on chlorophyll distribution in the Eastern Gulf of Alaska - ScienceDirect</title>   |   |   |   https://codeburst.io/a-guide-to-automating-scraping-the-web-with-javascript-chrome-puppeteer-node-js-b18efb9e9921

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment