]> ruderich.org/simon Gitweb - config/dotfiles.git/blobdiff - misc/lftp/rc
Move to misc/ in preparation for merge into new dotfiles repository
[config/dotfiles.git] / misc / lftp / rc
diff --git a/misc/lftp/rc b/misc/lftp/rc
new file mode 100644 (file)
index 0000000..ac70f49
--- /dev/null
@@ -0,0 +1,70 @@
+# lftp configuration file.
+
+# Copyright (C) 2007-2013  Simon Ruderich
+#
+# This file is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This file is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this file.  If not, see <http://www.gnu.org/licenses/>.
+
+
+# SETTINGS
+
+# Display all files (including hidden ones) with `ls`.
+set ftp:list-options -a
+
+# Enable colors in interactive mode. Used by e.g. directory listings (which
+# use $LS_COLORS).
+set color:use-color auto
+
+# Use a colorized prompt. Hostname in bold green, current directory in bold
+# blue.
+set cmd:prompt "lftp \[\e[01;32m\]\h\[\e[00m\]:\[\e[01;34m\]\w\[\e[00m\] % "
+
+
+# Store passwords in the bookmarks file.
+set bmk:save-passwords yes
+
+# Don't store current directory of each server in ~/.lftp/cwd_history.
+set cmd:save-cwd-history no
+# Don't store transfer logs in ~/.lftp/transfer_log.
+set xfer:log no
+
+
+# No retries after a failed connection, prevents (long) delays e.g. for
+# automated jobs.
+set net:max-retries 1
+
+# If SSL is used make sure the data connection is encrypted as well. This
+# should be the default behavior!.
+set ftp:ssl-protect-data yes
+set ftp:ssl-protect-fxp yes
+# Same for control connections (default).
+set ftp:ssl-protect-list yes
+# Make sure SSL is not dropped after a successful login (default).
+set ftp:ssl-use-ccc no
+# And verify the certificate and hostname, otherwise encryption doesn't matter
+# (default).
+set ssl:check-hostname yes
+set ssl:verify-certificate yes
+
+
+# ALIASES
+
+# Create "sync" command which syncs local directories with remote ones and
+# transfers all missing/outdated files. Local files which don't exist anymore
+# are removed on the server.
+alias sync mirror --verbose --reverse --delete --dereference
+
+# Create commands to go up directories.
+alias .. cd ..
+alias ... cd ../..
+alias .... cd ../../..