Commit Graph

20 Commits

Author SHA1 Message Date
Noam Postavsky
abfd259688 http callback: don't write-file directly to dest
When downloading a .gz file, if we actually write-file to that filename
the compressed data would be compressed a second time thanks to
auto-compress-mode. Instead, write to .part file first and then rename
to the destination, as it was before
92a39c84fe.
2014-06-07 19:23:54 -04:00
Noam Postavsky
92a39c84fe Don't cache http checksums.
- If the file was changed on the HTTP server before you restarted emacs,
  the checksum wouldn't be recomputed because it would be taken from the
  cache.

- The cached value was wrongly including the HTTP headers in the
  computation. Added a test for this.

- Computing a SHA1 is not so expensive that it needs the complication of
  caching.

* methods/el-get-http.el
(el-get-http-checksums): remove.
(el-get-http-retrieve-callback): don't compute hash on HTTP headers.
(el-get-http-compute-checksum): always compute a fresh hash.

* test/el-get-issue-1752.el: new test.
2014-05-28 18:01:52 -04:00
Noam Postavsky
bc9fea670e satisfy newer 24.4 byte compiler
It knows argument to eval-after-load is code, and that #' implies
existence of a function.

Some of the package.el functions have changed, but that will be dealt
with separately.
2014-04-04 19:13:27 -04:00
Noam Postavsky
5f689e1ec6 fix byte compiler warnings in methods/
Add requires or declare-functions as needed. Added some missing
variables (probably worked previously by dynamic binding).
2014-03-22 19:29:34 -04:00
Noam Postavsky
7cbe429fd3 emacswiki should default to base url for checksum
Since emacswiki recipes might not have an explicit :url in their recipe,
the :compute-checksum method should fallback to the base url, like the
:install and :guess-website methods.
2014-03-01 20:43:37 -05:00
Ryan C. Thompson
fdaaf51570 Cleanup indentation with custom indent rules 2014-03-01 16:19:46 -08:00
Ryan C. Thompson
cf34f9aa0a Clean up whitespace
This commit is the result of running cleanup-whitespace.sh.

Fixes #549.
2014-02-21 10:52:48 -08:00
Adam Spiers
1f5c12aef9 add debugging to el-get-http-retrieve-callback
Try to find out why it sometimes fails (e.g. see #1240).
2014-01-04 14:34:35 +00:00
Dimitri Fontaine
bddd695581 Merge pull request #1193 from rrthomas/http-fail
Handle HTTP errors in a user friendly way (report them).
2013-04-26 08:41:06 -07:00
Dimitri Fontaine
c2954adae4 Fix el-get-http-retrieve-callback to jump to beginning of buffer 2013-04-26 17:29:34 +02:00
Reuben Thomas
5d318414f1 Signal HTTP error when a file cannot be fetched 2013-04-21 19:02:59 +01:00
amazingjxq
c848a1d2f1 modify http method 2013-04-10 14:51:55 +08:00
Victor Deryagin
0a202ea35d changed mentions of 'README.asciidoc' to 'README.md' in source files 2013-04-01 15:46:34 +03:00
Ryan C. Thompson
9b350be579 Add website guessers to some methods 2012-02-28 17:58:44 -08:00
Ryan C. Thompson
3a5e6acac2 Update all el-get methods to declare using keywords 2012-02-12 02:29:31 -08:00
Ryan C. Thompson
573a0d1f98 Register ftp method as alias of http 2012-02-12 02:29:31 -08:00
Dimitri Fontaine
6e4f4007ea Review the :checksum patch, implement M-x el-get-checksum. 2011-10-28 18:02:38 +02:00
Gergely Risko
9205317d1d Implemented checksum support for http, ftp and emacswiki methods. 2011-10-27 18:28:09 +02:00
Dimitri Fontaine
8db0c4d49b Fix the refactoring so that it actually works.
This includes teaching methods that they now work with a symbolp PACKAGE,
some more cleaning up, and some load-path adjustments now that a part of the
code is in a subdirectory (methods).

Also include some of the tests used to convince oneself that the refactoring
didn't break any and all use cases for el-get, with some rough documentation
about how to use them.
2011-09-22 21:48:11 +02:00
Dimitri Fontaine
0433ca0ce9 Refactoring it all: a beginning. No time for testing yet, just showing ideas. 2011-09-20 15:15:52 +02:00