Merge branch 'master' of ssh://git-annex.branchable.com

This commit is contained in:
Joey Hess 2017-10-24 12:02:44 -04:00
commit bc82d226b6
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
3 changed files with 89 additions and 0 deletions

View file

@ -0,0 +1,13 @@
### Please describe the problem.
The metadata doesn't include the day for RSS feeds, which is probably only a problem for me as I've built something on top of the metadata to provide an interface for selecting podcasts.
### Please provide any additional information below.
The attached patch adds the day field to the metadata.
There's also a tiny bit extra for stack.yaml which will only affect people who have nix enabled in Stack and will make the build successful for those people.
### Have you had any luck using git-annex before? (Sometimes we get tired of reading bug reports all day and a lil' positive end note does wonders)
git-annex is awesome, I lean on it heavily nearly every single day.

View file

@ -0,0 +1,64 @@
[[!comment format=mdwn
username="seantparsons"
avatar="http://cdn.libravatar.org/avatar/616fb81847630239dd1ab099138cb685"
subject="Since the attachment doesn't appear to be there, here's the content."
date="2017-10-22T20:32:21Z"
content="""
diff --git a/Annex/MetaData.hs b/Annex/MetaData.hs
index e22ed05a6..355c5124a 100644
--- a/Annex/MetaData.hs
+++ b/Annex/MetaData.hs
@@ -60,10 +60,11 @@ dateMetaData :: UTCTime -> MetaData -> MetaData
dateMetaData mtime old = MetaData $ M.fromList $ filter isnew
[ (yearMetaField, S.singleton $ toMetaValue $ show y)
, (monthMetaField, S.singleton $ toMetaValue $ show m)
+ , (dayMetaField, S.singleton $ toMetaValue $ show d)
]
where
isnew (f, _) = S.null (currentMetaDataValues f old)
- (y, m, _d) = toGregorian $ utctDay mtime
+ (y, m, d) = toGregorian $ utctDay mtime
{- Parses field=value, field+=value, field-=value, field?=value -}
parseModMeta :: String -> Either String ModMeta
diff --git a/Annex/MetaData/StandardFields.hs b/Annex/MetaData/StandardFields.hs
index c91b53930..b9ea47e2f 100644
--- a/Annex/MetaData/StandardFields.hs
+++ b/Annex/MetaData/StandardFields.hs
@@ -9,6 +9,7 @@ module Annex.MetaData.StandardFields (
tagMetaField,
yearMetaField,
monthMetaField,
+ dayMetaField,
lastChangedField,
mkLastChangedField,
isLastChangedField
@@ -27,6 +28,9 @@ yearMetaField = mkMetaFieldUnchecked \"year\"
monthMetaField :: MetaField
monthMetaField = mkMetaFieldUnchecked \"month\"
+dayMetaField :: MetaField
+dayMetaField = mkMetaFieldUnchecked \"day\"
+
lastChangedField :: MetaField
lastChangedField = mkMetaFieldUnchecked lastchanged
diff --git a/stack.yaml b/stack.yaml
index d84c4682e..ac601200e 100644
--- a/stack.yaml
+++ b/stack.yaml
@@ -24,3 +24,11 @@ extra-deps:
explicit-setup-deps:
git-annex: true
resolver: lts-9.9
+nix:
+ packages:
+ - ncurses
+ - icu
+ - libcxx
+ - gcc
+ - zlib
+ - rsync
\ No newline at end of file
"""]]

View file

@ -0,0 +1,12 @@
[[!comment format=mdwn
username="ynikitenko"
avatar="http://cdn.libravatar.org/avatar/168d629704097ddc596f75ca32a687a3"
subject="same problem"
date="2017-10-24T09:31:06Z"
content="""
When could that be fixed?
I face the same problem. My repo is only about 2Gb, but it syncs quite slow (like minutes or tens of minutes, but with every smallest change that I want to be synced). I don't want to use other than version 6 and thin to save space, but it takes much time.
For another repo of 100 thousand files (though 2.6Gb) git-annex commit did not even work (I killed that after about 20 hours of work - it loaded the machine, created a lot of files (twice the size of the repo), but did not stop in that time).
"""]]