folders2web
A collection of scripts that I use to manage my academic workflow, many unfinished or very ideosyncratic
Science Score: 18.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
○codemeta.json file
-
○.zenodo.json file
-
○DOI references
-
○Academic links in README
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (0.8%) to scientific vocabulary
Last synced: 10 months ago
·
JSON representation
·
Repository
A collection of scripts that I use to manage my academic workflow, many unfinished or very ideosyncratic
Basic Info
- Host: GitHub
- Owner: houshuang
- Language: PHP
- Default Branch: master
- Homepage: http://reganmian.net/wiki/researchr:start
- Size: 10.6 MB
Statistics
- Stars: 41
- Watchers: 15
- Forks: 14
- Open Issues: 3
- Releases: 0
Created over 15 years ago
· Last pushed almost 12 years ago
Metadata Files
Changelog
Citation
Owner
- Name: Stian Håklev
- Login: houshuang
- Kind: user
- Location: Lausanne, Switzerland
- Company: EPFL
- Website: http://reganmian.net/blog
- Repositories: 171
- Profile: https://github.com/houshuang
Post-doc at CHILI lab, EPFL. Developing software for collaborative learning, learning analytics, collaborative editing, orchestration. React/Meteor stack.
Citation (citation.rb)
require 'net/http'
require 'rubygems'
require 'json'
require 'appscript'
include Appscript
$:.push(File.dirname($0))
require 'utility-functions'
puts "hello"
@bd = app("BibDesk").document
def send_citation(bibtex, hashkey)
host = Scrobble_server_host
port = Scrobble_server_port
post_ws = "/citations"
token = Scrobble_token
payload ={ "bibtex" => bibtex, "token" => token }.to_json
req = Net::HTTP::Post.new("/citations", initheader = {'Content-Type' =>'application/json'})
req.body = payload
response = Net::HTTP.new(host, port).start {|http| http.request(req) }
end
if ARGV[0] == "batch"
c=0
path = PDF_path + "/*.pdf"
growl "Beginning to send citation data to Scrobble server"
Dir[path].select do |f|
puts f
fname = File.basename(f)
citekey = fname[0..-5]
begin
bibtx = @bd.search({:for =>citekey})[0].BibTeX_string.get.to_s
hash = hashsum(f)
send_citation(bibtx, hash)
rescue
puts "#{citekey} not found in BibDesk database"
next
end
c = c+1
end
growl "Total #{c} entries sent"
end