instapaper 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (87) hide show
  1. data/{PostInstall.txt → .gemtest} +0 -0
  2. data/.gitignore +11 -0
  3. data/.rspec +3 -0
  4. data/.simplecov +1 -0
  5. data/.yardopts +3 -0
  6. data/Gemfile +2 -0
  7. data/LICENSE.md +20 -0
  8. data/README.md +152 -0
  9. data/Rakefile +13 -4
  10. data/instapaper.gemspec +33 -0
  11. data/lib/faraday/response/raise_http_1xxx.rb +65 -0
  12. data/lib/instapaper.rb +26 -10
  13. data/lib/instapaper/authentication.rb +32 -0
  14. data/lib/instapaper/client.rb +43 -0
  15. data/lib/instapaper/client/account.rb +13 -0
  16. data/lib/instapaper/client/bookmark.rb +81 -0
  17. data/lib/instapaper/client/folder.rb +34 -0
  18. data/lib/instapaper/client/user.rb +14 -0
  19. data/lib/instapaper/configuration.rb +88 -0
  20. data/lib/instapaper/connection.rb +35 -0
  21. data/lib/instapaper/request.rb +22 -9
  22. data/lib/instapaper/version.rb +1 -31
  23. data/spec/faraday/response_spec.rb +22 -0
  24. data/spec/fixtures/access_token.qline +1 -0
  25. data/spec/fixtures/bookmarks_add.json +1 -0
  26. data/spec/fixtures/bookmarks_archive.json +1 -0
  27. data/spec/fixtures/bookmarks_get_text.txt +299 -0
  28. data/spec/fixtures/bookmarks_list.json +5 -0
  29. data/spec/fixtures/bookmarks_move.json +1 -0
  30. data/spec/fixtures/bookmarks_star.json +1 -0
  31. data/spec/fixtures/bookmarks_unarchive.json +1 -0
  32. data/spec/fixtures/bookmarks_unstar.json +1 -0
  33. data/spec/fixtures/bookmarks_update_read_progress.json +1 -0
  34. data/spec/fixtures/folders_add.json +1 -0
  35. data/spec/fixtures/folders_delete.json +1 -0
  36. data/spec/fixtures/folders_list.json +1 -0
  37. data/spec/fixtures/folders_set_order.json +1 -0
  38. data/spec/fixtures/verify_credentials.json +1 -0
  39. data/spec/instapaper/client/account_spec.rb +27 -0
  40. data/spec/instapaper/client/bookmark_spec.rb +234 -0
  41. data/spec/instapaper/client/folder_spec.rb +89 -0
  42. data/spec/instapaper/client/user_spec.rb +28 -0
  43. data/spec/instapaper/client_spec.rb +65 -0
  44. data/spec/instapaper_spec.rb +85 -0
  45. data/spec/spec_helper.rb +44 -0
  46. metadata +230 -99
  47. data/History.txt +0 -3
  48. data/Manifest.txt +0 -43
  49. data/README.rdoc +0 -73
  50. data/config/hoe.rb +0 -73
  51. data/config/requirements.rb +0 -15
  52. data/lib/instapaper/base.rb +0 -113
  53. data/lib/instapaper/constants.rb +0 -37
  54. data/lib/instapaper/exceptions.rb +0 -41
  55. data/lib/instapaper/protocol.rb +0 -47
  56. data/lib/instapaper/request/abstract_request.rb +0 -104
  57. data/lib/instapaper/request/add_url_request.rb +0 -68
  58. data/lib/instapaper/request/authentication_request.rb +0 -60
  59. data/lib/instapaper/request/request_error.rb +0 -34
  60. data/lib/instapaper/request/request_errors.rb +0 -41
  61. data/lib/instapaper/request/request_validation.rb +0 -34
  62. data/lib/instapaper/response.rb +0 -10
  63. data/lib/instapaper/response/abstract_response.rb +0 -38
  64. data/lib/instapaper/response/add_url_success_response.rb +0 -41
  65. data/lib/instapaper/response/authentication_invalid_response.rb +0 -40
  66. data/lib/instapaper/response/authentication_success_response.rb +0 -40
  67. data/lib/instapaper/response/bad_request_response.rb +0 -40
  68. data/lib/instapaper/response/response_builder.rb +0 -61
  69. data/lib/instapaper/response/service_error_response.rb +0 -40
  70. data/script/console +0 -10
  71. data/script/destroy +0 -14
  72. data/script/generate +0 -14
  73. data/script/txt2html +0 -82
  74. data/setup.rb +0 -1585
  75. data/tasks/deployment.rake +0 -34
  76. data/tasks/environment.rake +0 -7
  77. data/tasks/website.rake +0 -17
  78. data/test/test_auth.rb +0 -62
  79. data/test/test_error.rb +0 -81
  80. data/test/test_helper.rb +0 -2
  81. data/test/test_instapaper.rb +0 -9
  82. data/test/test_request.rb +0 -45
  83. data/website/index.html +0 -99
  84. data/website/index.txt +0 -69
  85. data/website/javascripts/rounded_corners_lite.inc.js +0 -285
  86. data/website/stylesheets/screen.css +0 -138
  87. data/website/template.html.erb +0 -48
@@ -1,138 +0,0 @@
1
- body {
2
- background-color: #E1D1F1;
3
- font-family: "Georgia", sans-serif;
4
- font-size: 16px;
5
- line-height: 1.6em;
6
- padding: 1.6em 0 0 0;
7
- color: #333;
8
- }
9
- h1, h2, h3, h4, h5, h6 {
10
- color: #444;
11
- }
12
- h1 {
13
- font-family: sans-serif;
14
- font-weight: normal;
15
- font-size: 4em;
16
- line-height: 0.8em;
17
- letter-spacing: -0.1ex;
18
- margin: 5px;
19
- }
20
- li {
21
- padding: 0;
22
- margin: 0;
23
- list-style-type: square;
24
- }
25
- a {
26
- color: #5E5AFF;
27
- background-color: #DAC;
28
- font-weight: normal;
29
- text-decoration: underline;
30
- }
31
- blockquote {
32
- font-size: 90%;
33
- font-style: italic;
34
- border-left: 1px solid #111;
35
- padding-left: 1em;
36
- }
37
- .caps {
38
- font-size: 80%;
39
- }
40
-
41
- #main {
42
- width: 45em;
43
- padding: 0;
44
- margin: 0 auto;
45
- }
46
- .coda {
47
- text-align: right;
48
- color: #77f;
49
- font-size: smaller;
50
- }
51
-
52
- table {
53
- font-size: 90%;
54
- line-height: 1.4em;
55
- color: #ff8;
56
- background-color: #111;
57
- padding: 2px 10px 2px 10px;
58
- border-style: dashed;
59
- }
60
-
61
- th {
62
- color: #fff;
63
- }
64
-
65
- td {
66
- padding: 2px 10px 2px 10px;
67
- }
68
-
69
- .success {
70
- color: #0CC52B;
71
- }
72
-
73
- .failed {
74
- color: #E90A1B;
75
- }
76
-
77
- .unknown {
78
- color: #995000;
79
- }
80
- pre, code {
81
- font-family: monospace;
82
- font-size: 90%;
83
- line-height: 1.4em;
84
- color: #ff8;
85
- background-color: #111;
86
- padding: 2px 10px 2px 10px;
87
- }
88
- .comment { color: #aaa; font-style: italic; }
89
- .keyword { color: #eff; font-weight: bold; }
90
- .punct { color: #eee; font-weight: bold; }
91
- .symbol { color: #0bb; }
92
- .string { color: #6b4; }
93
- .ident { color: #ff8; }
94
- .constant { color: #66f; }
95
- .regex { color: #ec6; }
96
- .number { color: #F99; }
97
- .expr { color: #227; }
98
-
99
- #version {
100
- float: right;
101
- text-align: right;
102
- font-family: sans-serif;
103
- font-weight: normal;
104
- background-color: #B3ABFF;
105
- color: #141331;
106
- padding: 15px 20px 10px 20px;
107
- margin: 0 auto;
108
- margin-top: 15px;
109
- border: 3px solid #141331;
110
- }
111
-
112
- #version .numbers {
113
- display: block;
114
- font-size: 4em;
115
- line-height: 0.8em;
116
- letter-spacing: -0.1ex;
117
- margin-bottom: 15px;
118
- }
119
-
120
- #version p {
121
- text-decoration: none;
122
- color: #141331;
123
- background-color: #B3ABFF;
124
- margin: 0;
125
- padding: 0;
126
- }
127
-
128
- #version a {
129
- text-decoration: none;
130
- color: #141331;
131
- background-color: #B3ABFF;
132
- }
133
-
134
- .clickable {
135
- cursor: pointer;
136
- cursor: hand;
137
- }
138
-
@@ -1,48 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <link rel="stylesheet" href="stylesheets/screen.css" type="text/css" media="screen" />
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <title>
8
- <%= title %>
9
- </title>
10
- <script src="javascripts/rounded_corners_lite.inc.js" type="text/javascript"></script>
11
- <style>
12
-
13
- </style>
14
- <script type="text/javascript">
15
- window.onload = function() {
16
- settings = {
17
- tl: { radius: 10 },
18
- tr: { radius: 10 },
19
- bl: { radius: 10 },
20
- br: { radius: 10 },
21
- antiAlias: true,
22
- autoPad: true,
23
- validTags: ["div"]
24
- }
25
- var versionBox = new curvyCorners(settings, document.getElementById("version"));
26
- versionBox.applyCornersToAll();
27
- }
28
- </script>
29
- </head>
30
- <body>
31
- <div id="main">
32
-
33
- <h1><%= title %></h1>
34
- <div id="version" class="clickable" onclick='document.location = "<%= download %>"; return false'>
35
- <p>Get Version</p>
36
- <a href="<%= download %>" class="numbers"><%= version %></a>
37
- </div>
38
- <%= body %>
39
- <p class="coda">
40
- <a href="mailto:douglas.willcocks@gmail.com">Douglas Willcocks</a>, <%= modified.pretty %><br>
41
- Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
42
- </p>
43
- </div>
44
-
45
- <!-- insert site tracking codes here, like Google Urchin -->
46
-
47
- </body>
48
- </html>