summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Annex/Version.hs11
-rw-r--r--Command/Direct.hs2
-rw-r--r--Command/Indirect.hs2
-rw-r--r--Command/Upgrade.hs2
-rw-r--r--Init.hs3
-rw-r--r--Makefile4
-rw-r--r--Upgrade/V1.hs4
-rw-r--r--debian/changelog3
-rw-r--r--doc/design/assistant.mdwn2
-rw-r--r--doc/design/assistant/android.mdwn3
-rw-r--r--doc/git-annex.mdwn2
-rw-r--r--doc/upgrades.mdwn5
-rw-r--r--git-annex.cabal1
-rwxr-xr-xstandalone/android/runshell3
14 files changed, 33 insertions, 14 deletions
diff --git a/Annex/Version.hs b/Annex/Version.hs
index 6149e6fb7..31c6501be 100644
--- a/Annex/Version.hs
+++ b/Annex/Version.hs
@@ -1,6 +1,6 @@
{- git-annex repository versioning
-
- - Copyright 2010 Joey Hess <joey@kitenet.net>
+ - Copyright 2010,2013 Joey Hess <joey@kitenet.net>
-
- Licensed under the GNU GPL version 3 or higher.
-}
@@ -16,8 +16,11 @@ type Version = String
defaultVersion :: Version
defaultVersion = "3"
+directModeVersion :: Version
+directModeVersion = "4"
+
supportedVersions :: [Version]
-supportedVersions = [defaultVersion]
+supportedVersions = [defaultVersion, directModeVersion]
upgradableVersions :: [Version]
upgradableVersions = ["0", "1", "2"]
@@ -28,8 +31,8 @@ versionField = annexConfig "version"
getVersion :: Annex (Maybe Version)
getVersion = annexVersion <$> Annex.getGitConfig
-setVersion :: Annex ()
-setVersion = setConfig versionField defaultVersion
+setVersion :: Version -> Annex ()
+setVersion = setConfig versionField
removeVersion :: Annex ()
removeVersion = unsetConfig versionField
diff --git a/Command/Direct.hs b/Command/Direct.hs
index 0c007bb10..d847a3270 100644
--- a/Command/Direct.hs
+++ b/Command/Direct.hs
@@ -14,6 +14,7 @@ import qualified Git.Command
import qualified Git.LsFiles
import Config
import Annex.Direct
+import Annex.Version
def :: [Command]
def = [notBareRepo $
@@ -53,4 +54,5 @@ cleanup :: CommandCleanup
cleanup = do
showStart "direct" ""
setDirect True
+ setVersion directModeVersion
return True
diff --git a/Command/Indirect.hs b/Command/Indirect.hs
index ac97be753..8bf228a80 100644
--- a/Command/Indirect.hs
+++ b/Command/Indirect.hs
@@ -17,6 +17,7 @@ import qualified Annex
import Annex.Direct
import Annex.Content
import Annex.CatFile
+import Annex.Version
import Init
def :: [Command]
@@ -88,6 +89,7 @@ perform = do
cleanup :: CommandCleanup
cleanup = do
+ setVersion defaultVersion
showStart "indirect" ""
showEndOk
return True
diff --git a/Command/Upgrade.hs b/Command/Upgrade.hs
index b39fcd99c..d1c1eb3b0 100644
--- a/Command/Upgrade.hs
+++ b/Command/Upgrade.hs
@@ -23,5 +23,5 @@ start :: CommandStart
start = do
showStart "upgrade" "."
r <- upgrade
- setVersion
+ setVersion defaultVersion
next $ next $ return r
diff --git a/Init.hs b/Init.hs
index 2c1bf4ef9..358a54e81 100644
--- a/Init.hs
+++ b/Init.hs
@@ -42,9 +42,9 @@ genDescription Nothing = do
initialize :: Maybe String -> Annex ()
initialize mdescription = do
prepUUID
+ setVersion defaultVersion
checkCrippledFileSystem
Annex.Branch.create
- setVersion
gitPreCommitHookWrite
createInodeSentinalFile
u <- getUUID
@@ -143,3 +143,4 @@ checkCrippledFileSystem = whenM (probeCrippledFileSystem) $ do
maybe noop (`toDirect` f) =<< isAnnexLink f
void $ liftIO clean
setDirect True
+ setVersion directModeVersion
diff --git a/Makefile b/Makefile
index 15300aed4..5ea76c0e0 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,7 @@ BASEFLAGS=-Wall -outputdir $(GIT_ANNEX_TMP_BUILD_DIR) -IUtility
# you can turn off some of these features.
#
# If you're using an old version of yesod, enable -DWITH_OLD_YESOD
-FEATURES?=$(GIT_ANNEX_LOCAL_FEATURES) -DWITH_ASSISTANT -DWITH_S3 -DWITH_WEBDAV -DWITH_WEBAPP -DWITH_PAIRING -DWITH_XMPP -DWITH_DNS -DWITH_GLOB
+FEATURES?=$(GIT_ANNEX_LOCAL_FEATURES) -DWITH_ASSISTANT -DWITH_S3 -DWITH_WEBDAV -DWITH_WEBAPP -DWITH_PAIRING -DWITH_XMPP -DWITH_DNS
bins=git-annex
mans=git-annex.1 git-annex-shell.1
@@ -234,7 +234,7 @@ android:
OS=Android $(MAKE) Build/SysConfig.hs
GHC=$$HOME/.ghc/android-14/arm-linux-androideabi-4.7/bin/arm-unknown-linux-androideabi-ghc \
CC=$$HOME/.ghc/android-14/arm-linux-androideabi-4.7/bin/arm-linux-androideabi-gcc \
- FEATURES="-DWITH_ANDROID -DWITH_ASSISTANT -DWITH_GLOB -DWITH_DNS" \
+ FEATURES="-DWITH_ANDROID -DWITH_ASSISTANT -DWITH_DNS" \
OS=Android $(MAKE) fast
ANDROIDAPP_DEST=$(GIT_ANNEX_TMP_BUILD_DIR)/git-annex.android
diff --git a/Upgrade/V1.hs b/Upgrade/V1.hs
index 966b51a44..72e105d16 100644
--- a/Upgrade/V1.hs
+++ b/Upgrade/V1.hs
@@ -53,14 +53,14 @@ upgrade = do
ifM (fromRepo Git.repoIsLocalBare)
( do
moveContent
- setVersion
+ setVersion defaultVersion
, do
moveContent
updateSymlinks
moveLocationLogs
Annex.Queue.flush
- setVersion
+ setVersion defaultVersion
)
Upgrade.V2.upgrade
diff --git a/debian/changelog b/debian/changelog
index 4d63ef9b8..091d16d1d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,6 @@
-git-annex (3.20130217) UNRELEASED; urgency=low
+git-annex (4.20130217) UNRELEASED; urgency=low
+ * annex.version is now set to 4 for direct mode repositories.
* Should now fully support git repositories with core.symlinks=false;
always using git's pseudosymlink files in such repositories.
* webapp: Allow creating repositories on filesystems that lack support for
diff --git a/doc/design/assistant.mdwn b/doc/design/assistant.mdwn
index ad1c6abd1..bbe1857a1 100644
--- a/doc/design/assistant.mdwn
+++ b/doc/design/assistant.mdwn
@@ -13,10 +13,10 @@ and use cases to add. Feel free to chip in with comments! --[[Joey]]
* Month 6 "9k bonus round": [[!traillink desymlink]]
* Month 7: user-driven features and polishing;
[presentation at LCA2013](http://mirror.linux.org.au/linux.conf.au/2013/mp4/gitannex.mp4)
+* Month 8: [[!traillink Android]]
We are, approximately, here:
-* Month 8: [[!traillink Android]]
* Months 9-11: more user-driven features and polishing (see remaining TODO items in all pages above)
* Month 12: "Windows purgatory" [[Windows]]
diff --git a/doc/design/assistant/android.mdwn b/doc/design/assistant/android.mdwn
index daa08bf5e..a338a38ab 100644
--- a/doc/design/assistant/android.mdwn
+++ b/doc/design/assistant/android.mdwn
@@ -30,3 +30,6 @@ transfers when not on wifi. This may need to be configurable.
allow git to link to it.
* getEnvironment is broken on Android <https://github.com/neurocyte/ghc-android/issues/7>
and a few places use it.
+* Enable WebDAV support. Currently needs template haskell (could be avoided
+ by changing the DAV library to not use it), and also networking support,
+ which seems broken in current ghc-android.
diff --git a/doc/git-annex.mdwn b/doc/git-annex.mdwn
index a06ac3802..3b2af9cb5 100644
--- a/doc/git-annex.mdwn
+++ b/doc/git-annex.mdwn
@@ -191,7 +191,7 @@ subdirectories).
Typically started at boot, or when you log in.
With the --autostart option, the assistant is started in any repositories
- it has created.
+ it has created. These are listed in `~/.config/git-annex/autostart`
* webapp
diff --git a/doc/upgrades.mdwn b/doc/upgrades.mdwn
index c4aac5348..6cf54477c 100644
--- a/doc/upgrades.mdwn
+++ b/doc/upgrades.mdwn
@@ -18,6 +18,11 @@ conflicts first before upgrading git-annex.
## Upgrade events, so far
+### v3 -> v4 (git-annex version 4.x)
+
+v4 is only used for [[direct_mode]], and no upgrade needs to be done from
+existing v3 repositories, they will continue to work.
+
### v2 -> v3 (git-annex version 3.x)
Involved moving the .git-annex/ directory into a separate git-annex branch.
diff --git a/git-annex.cabal b/git-annex.cabal
index 3383a6895..37badef31 100644
--- a/git-annex.cabal
+++ b/git-annex.cabal
@@ -132,7 +132,6 @@ Test-Suite test
C-Sources: Utility/libdiskfree.c
Extensions: CPP
GHC-Options: -threaded
- CPP-Options: -DWITH_GLOB
source-repository head
type: git
diff --git a/standalone/android/runshell b/standalone/android/runshell
index 8e6c12462..5c0952721 100755
--- a/standalone/android/runshell
+++ b/standalone/android/runshell
@@ -100,6 +100,9 @@ run () {
shift 1
exec "$cmd" "$@"
else
+ if $cmd test -e "$HOME/.config/git-annex/autostart; then
+ git annex assistant --autostart || $cmd true
+ fi
/system/bin/sh
fi
}