summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-09-08 02:02:39 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-09-08 02:02:39 -0400
commit0c01348b65bb3d0364f90ce9785236fa05985f75 (patch)
treec96bb6612882c6db04a8a4b48f34dead0f6ec3c6 /templates
parent3bee6b3c74cede7c9099e6bf298ffa585ebf3b80 (diff)
pairing passphrase entry form, validation, etc
Actually 3 forms in one, this handles the initial passphrase entry, and the confirmation, and also varys wording if the same user or a different user is confirming.
Diffstat (limited to 'templates')
-rw-r--r--templates/configurators/pairing.hamlet50
-rw-r--r--templates/configurators/repositories.hamlet3
2 files changed, 52 insertions, 1 deletions
diff --git a/templates/configurators/pairing.hamlet b/templates/configurators/pairing.hamlet
new file mode 100644
index 000000000..4aa1cdbb0
--- /dev/null
+++ b/templates/configurators/pairing.hamlet
@@ -0,0 +1,50 @@
+<div .span9 .hero-unit>
+ <h2>
+ Pairing with a local computer
+ <p>
+ $if start
+ Pair with a computer on your local network (or VPN), and the #
+ two git annex repositories will be combined into one, with changes #
+ kept in sync between all paired devices.
+ $else
+ Pairing with #{username}@#{hostname} will combine the two git annex #
+ repositories into one, with changes kept in sync between them.
+ <p>
+ $if start
+ For security, enter a secret phrase. This same secret phrase will #
+ also need to be entered on the computer you're pairing with. #
+ It will be used to verify you're pairing with the right computer.
+ $else
+ $if sameusername
+ For security, you need to enter the same secret phrase that was #
+ entered on #{hostname} when the pairing was started.
+ $else
+ For security, a secret phrase has been selected, which you need #
+ to enter here to complete the pairing. If you don't know the #
+ phrase, go ask #{username} ...
+ $if badphrase
+ <div .alert .alert-error>
+ <i .icon-warning-sign></i> #{msg}
+ <p>
+ <form .form-horizontal enctype=#{enctype}>
+ <fieldset>
+ ^{form}
+ ^{authtoken}
+ <div .form-actions>
+ <button .btn .btn-primary type=submit>
+ $if start
+ Start pairing
+ $else
+ Complete pairing
+ <div .alert .alert-info>
+ $if start
+ <p>
+ A good secret phrase is reasonably long. You'll only #
+ type it a few times. Only letters and numbers matter; #
+ punctuation and white space is ignored.
+ <p>
+ A quotation is one good choice, something like: #
+ "#{sampleQuote}"
+ $else
+ Only letters and numbers matter; punctuation and white space is #
+ ignored.
diff --git a/templates/configurators/repositories.hamlet b/templates/configurators/repositories.hamlet
index d33a1554b..a38ec10af 100644
--- a/templates/configurators/repositories.hamlet
+++ b/templates/configurators/repositories.hamlet
@@ -26,7 +26,8 @@
between computers.
<h3>
- <i .icon-plus-sign></i> Local computer
+ <a href="@{StartPairR}">
+ <i .icon-plus-sign></i> Local computer
<p>
Pair with a local computer to automatically keep files in sync #
between computers on your local network.