Skip to content

Instantly share code, notes, and snippets.

@secretGeek
Created February 11, 2016 00:59
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save secretGeek/ba0cfa2cf35af1be2d3a to your computer and use it in GitHub Desktop.
Save secretGeek/ba0cfa2cf35af1be2d3a to your computer and use it in GitHub Desktop.
LinqPad script that downloads all PDFs/etc from Bret Victors worry dream refs page.
void Main()
{
// LinqPad script that downloads all PDFs/etc from Bret Victors worry dream refs page.
var targetPath = @"PATH_TO_WHERE_YOU_KEEP_YOUR_EBOOK\eBooks";
//These filenames were extracted from http://worrydream.com/refs/ -- using NimbleText.
//(TODO: Use regex or html agility pack to find them programmatically)
var refs = new string[] {
"Hamming-TheArtOfDoingScienceAndEngineering.pdf",
"Licklider-IntergalacticNetwork.pdf",
"Sutherland-Sketchpad.pdf",
"Backus-CanProgrammingBeLiberated.pdf",
"Hewitt-ActorModel.pdf",
"Griswold-TheSnobolProgrammingLanguage.pdf",
"Hestenes-ReformingTheMathematicalLanguageOfPhysics.pdf",
"FoundingOfTheAILab.pdf",
"Lockhart-MathematiciansLament.pdf",
"Nelson-ComputerLibDreamMachines1975.pdf",
"Crowe-HistoryOfVectorAnalysis.pdf",
"Watts-CollectiveDynamicsOfSmallWorldNetworks.pdf",
"Barton%20-%20A%20New%20Approach%20to%20the%20Functional%20Design%20of%20a%20New%20Computer.pdf",
"Bush%20-%20The%20Differential%20Analyzer.pdf",
"Shannon%20-%20A%20Mathematical%20Theory%20of%20Communication.pdf",
"Hadamard%20-%20The%20psychology%20of%20invention%20in%20the%20mathematical%20field.pdf",
"Licklider%20-%20The%20Computer%20as%20Communication%20Device.pdf",
"Licklider%20-%20Libraries%20of%20the%20Future.pdf",
"Minsky%20-%20Why%20programming%20is%20a%20good%20medium%20for%20expressing%20poorly%20understood%20and%20sloppily-formulated%20ideas.pdf",
"Sussman%20-%20Building%20Robust%20Systems.pdf",
"Kay%20-%20Personal%20Dynamic%20Media.pdf",
"Kay%20-%20Programming%20and%20Programming%20Languages.pdf",
"Kay%20-%20The%20Center%20of%20Why.pdf",
"Kay%20-%20The%20Real%20Computer%20Revolution%20Hasn%e2%80%99t%20Happened%20Yet.pdf",
"Kay%20-%20User%20Interface,%20a%20Personal%20View.pdf",
"Sutherland%20-%20Tyranny%20of%20the%20Clock.pdf",
"Kay%20-%20Computer%20Software%20-%20SciAm.pdf",
"Sutherland%20-%20Sketchpad%20Report.pdf",
"Engelbart%20-%20Improving%20Our%20Ability%20to%20Improve.pdf",
"Engelbart%20-%20Augmenting%20Human%20Intellect.pdf",
"Licklider%20-%20Interactive%20Information%20Processing,%20Retrieval,%20and%20Transfer.pdf",
"Licklider%20-%20Man-Computer%20Symbiosis.pdf",
"Taylor%20-%20Oral%20History.pdf",
"Latour%20-%20Visualisation%20and%20Cognition.pdf",
"Kay%20-%20NSF%20proposal.pdf",
"Cohn%20-%20Comics,%20Linguistics,%20and%20Visual%20Language.pdf",
"Hofstadter%20-%20To%20Err%20Is%20Human.pdf",
"Kay%20-%20Opening%20the%20Hood%20of%20a%20Word%20Processor.pdf",
"Thurston%20-%20Mathematical%20Education.pdf",
"diSessa%20-%20Knowledge%20in%20Pieces.pdf",
"Mead%20-%20American%20Spectator%20Interview.html",
"Hofstadter%20-%20Analogy%20as%20the%20Core%20of%20Cognition.pdf",
"Hestenes%20-%20Modeling%20games%20in%20the%20Newtonian%20World.pdf",
"Borwein%20-%20Aesthetics%20for%20the%20Working%20Mathematician.pdf",
"Mead%20-%20Gene%20Youngblood%20Interview.pdf",
"Papert%20-%20Whats%20the%20Big%20Idea.pdf",
"Mason%20-%20When%20is%20a%20Symbol%20Symbolic.pdf",
"Papert%20-%20Beyond%20The%20Cognitive.pdf",
"Cook%20-%20How%20Complex%20Systems%20Fail.pdf",
"Hamming%20-%20One%20Man's%20View%20of%20Computer%20Science.pdf",
"Sussman%20-%20Robust%20Design%20through%20Diversity.pdf",
"Moore%20-%20Forth%20-%20The%20Early%20Years.pdf",
"Bush%20-%20Memex%20Revisited.pdf",
"Bush%20-%20As%20We%20May%20Think%20(with%20Engelbart%20notes).pdf",
"Bush%20-%20As%20We%20May%20Think%20(Life%20Magazine%209-10-1945).pdf",
"Engelbart%20-%20Augmenting%20Human%20Intellect%20(typeset).pdf",
"Kay%20-%20What%20is%20a%20Dynabook.pdf",
"Jaynes%20-%20Clearing%20up%20Mysteries.pdf",
"Hestenes%20-%20An%20Interview%20with%20David%20Hestenes.pdf",
"Hestenes%20-%20Secrets%20of%20Genius.pdf",
"Stewart%20-%20Hermann%20Grassmann%20was%20Right.pdf",
"Thurston%20-%20On%20Proof%20and%20Progress%20in%20Mathematics.pdf",
"Pike%20-%20Systems%20Software%20Research%20is%20Irrelevant.pdf",
"Wirth%20-%20Project%20Oberon.pdf",
"Shannon%20-%20Communication%20Theory%20of%20Secrecy%20Systems.pdf",
"Landauer%20-%20Irreversibility%20and%20Heat%20Generation%20in%20the%20Computing%20Process.pdf",
"Luzin%20-%20The%20Evolution%20of%20Function%20Part%20II.pdf",
"Bennett%20-%20Logical%20Reversibility%20of%20Computation.pdf",
"Minsky%20-%20Steps%20Toward%20Artificial%20Intelligence.pdf",
"Postman%20-%20Five%20Things%20We%20Need%20to%20Know%20About%20Technological%20Change.pdf",
"Landauer%20-%20Zig-Zag%20Path%20to%20Understanding.pdf",
"Hoare%20-%20The%20Emperors%20Old%20Clothes.pdf",
"Meijer%20-%20Functional%20Programming%20with%20Bananas,%20Lenses,%20Envelopes%20and%20Barbed%20Wire.pdf",
"Licklider%20-%20Online%20Man-Computer%20Communication.pdf",
"Lamport%20-%20The%20Future%20of%20Computing%20-%20Logic%20or%20Biology.pdf",
"Landin%20-%20The%20Next%20700%20Programming%20Languages.pdf",
"Sutherland%20-%20The%20Ultimate%20Display.pdf",
"Lapham%20-%20The%20Eternal%20Now.pdf",
"Wigner%20-%20The%20Unreasonable%20Effectiveness%20of%20Mathematics%20in%20the%20Natural%20Sciences.pdf",
"Brooks-NoSilverBullet.pdf",
"Hughes-WhyFunctionalProgrammingMatters.pdf",
"Compton%20-%20The%20Genesis%20of%20a%20Curriculum%20in%20Biological%20Engineering.pdf",
"Zhang%20-%20Representations%20in%20Distributed%20Cognitive%20Tasks.pdf",
"Lamport%20-%20How%20to%20Write%20a%2021st%20Century%20Proof.pdf",
"Goody%20-%20The%20Consequences%20of%20Literacy.pdf",
"Sutherland%20-%20Technology%20and%20Courage.pdf",
"Wilson%20-%20Six%20views%20of%20embodied%20cognition.pdf",
"diSessa%20-%20Momentum%20flow%20as%20an%20alternative%20perspective%20in%20elementary%20mechanics.pdf",
"Kay%20-%20A%20Personal%20Computer%20for%20Children%20of%20All%20Ages.pdf",
"Mead%20-%20The%20Nature%20of%20Light%20-%20What%20are%20Photons..pdf",
"Kay%20-%20Playground%20Essays.pdf",
"Jaynes%20-%20Probability%20in%20Quantum%20Theory.pdf",
"Jaynes%20-%20The%20Gibbs%20Paradox.pdf",
"Jaynes%20-%20The%20Evolution%20of%20Carnot's%20Principle.pdf",
"Jaynes%20-%20Some%20Random%20Observations.pdf",
"Jaynes%20-%20Notes%20on%20Present%20Status%20and%20Future%20Progress.pdf",
"Wadge%20-%20Lucid,%20the%20Dataflow%20Programming%20Language.pdf",
"Lamport%20-%20Time,%20Clocks,%20and%20the%20Ordering%20of%20Events%20in%20a%20Distributed%20System.pdf",
"Carriero%20-%20Linda%20in%20Context.pdf",
"Lenat%20-%20Heuretics.pdf",
"Lenat%20-%20Voice%20of%20the%20Turtle.pdf",
"Lenat%20-%20Why%20AM%20and%20Eurisko%20Appear%20to%20Work.pdf",
"Engelbart%20-%20Games%20That%20Teach%20the%20Fundamentals%20of%20Computer%20Operation.pdf",
"Sutherland%20-%20Microelectronics%20and%20Computer%20Science.pdf",
"Aspray%20-%20JCR%20Licklider%20Interview.pdf",
"Stallman%20-%20EMACS,%20The%20Extensible,%20Customizable,%20Self-Documenting%20Display%20Editor.pdf",
"Papert%20-%20Teaching%20Children%20to%20be%20Mathematicians%20Versus%20Teaching%20About%20Mathematics.pdf",
"Cox%20-%20Probability,%20Frequency%20and%20Reasonable%20Expectation.pdf",
"Barthes%20-%20From%20Work%20to%20Text.pdf",
"Vannevar%20Bush%20Symposium%20-%20Closing%20Panel.html",
"Kennedy%20-%20Administration%20of%20Research%20in%20a%20Research%20Corporation%20table.png",
"Kennedy%20-%20Administration%20of%20Research%20in%20a%20Research%20Corporation.html",
"Bolt%20-%20Spatial%20Data%20Management.pdf",
"Lampson%20-%20Alto%20User's%20Handbook.pdf",
"Teitelman%20-%20The%20Cedar%20Programming%20Environment,%20A%20Midterm%20Report%20and%20Examination.pdf",
"Xerox%20Star%20Learner's%20Guide.pdf",
"Smith%20-%20Croquet%20-%20A%20Collaboration%20System%20Architecture.pdf",
"Tesler%20-%20A%20Personal%20History%20of%20Modeless%20Text%20Editing%20and%20Cut-Copy-Paste.pdf",
"Mead%20-%20Oral%20History%20Cohen.pdf",
"Kurlander%20-%20A%20History-Based%20Macro%20By%20Example%20System.pdf",
"Kurlander%20-%20Editable%20Graphical%20Histories.pdf",
"Kurlander-%20Inferring%20Constraints%20from%20Multiple%20Snapshots.pdf",
"Meyers%20-%20Scripting%20Graphical%20Applications%20by%20Demonstration.pdf",
"Buxton%20-%20Interaction%20at%20Lincoln%20Laboratory%20in%20the%201960.pdf",
"Myers%20-%20Scripting%20Graphical%20Applications%20by%20Demonstration.pdf",
"Clark%20-%20TX-2%20papers.pdf",
"Kay%20-%20Powerful%20Ideas%20Need%20Love%20Too.html",
"Conway%20-%20Reminiscences%20of%20the%20VLSI%20Revolution.pdf",
"Hillis%20-%20The%20Connection%20Machine.pdf",
"Fenton%20-%20Playground.pdf",
"Smith%20-%20Pygmalion.pdf",
"Shannon%20-%20The%20Bandwagon.pdf",
};
//var r = refs[0];
using (var client = new System.Net.WebClient()) {
foreach(var r in refs) {
var remoteFile = "http://worrydream.com/refs/" + r;
var localFile = Path.Combine(targetPath, System.Uri.UnescapeDataString(r));
if (!File.Exists(localFile)) {
Console.Write("Downloading: " + System.Uri.UnescapeDataString(r));
try {
Console.Write("...");
client.DownloadFile(remoteFile, localFile);
Console.Write("...");
} catch(System.Exception ex) {
Console.WriteLine("**** Exception!\r\n" + ex.ToString());
}
Console.WriteLine("");
//Wait 3 seconds between each file download, to be respectful to the server
System.Threading.Thread.Sleep(3000);
} else {
Console.WriteLine("Already have: " + System.Uri.UnescapeDataString(r));
}
}
}
}
// Define other methods and classes here
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment