Merge https://github.com/owncloud/mirall into fix_folder_status_ui_ignore_new_line_inoverall_text
|
@ -140,6 +140,7 @@ set(TRANSLATIONS ${TRANS_FILES})
|
|||
|
||||
add_subdirectory(csync)
|
||||
add_subdirectory(src)
|
||||
add_subdirectory(shell_integration)
|
||||
add_subdirectory(doc)
|
||||
|
||||
if(UNIT_TESTING)
|
||||
|
|
30
ChangeLog
|
@ -1,5 +1,35 @@
|
|||
ChangeLog
|
||||
=========
|
||||
version 1.6.2 (release 2014-07-x )
|
||||
* HTTP Credentials: Read password from legacy place if not found.
|
||||
* Shibboleth: Fix the waiting curser that would not disapear (#1915)
|
||||
* Limit memory usage to avoid mem wasting and crashes
|
||||
* Propagator: Fix crash when logging out during upload (#1957)
|
||||
* Propagator_qnam: Fix signal slot connection (#1963)
|
||||
* Use more elaborated way to detect that the server was reconfigured (#1948)
|
||||
* Setup Wizard: Reconfigure Server also if local path was changed (#1948)
|
||||
|
||||
version 1.6.1 (release 2014-06-26 )
|
||||
* Fix 'precondition failed' bug with broken upload
|
||||
* Fix openSSL problems for windows deployment
|
||||
* Fix syncing a folder with '#' in the name
|
||||
* Fix #1845: do not update parent directory etag before sub
|
||||
directories are removed
|
||||
* Fix reappearing directories if dirs are removed during its
|
||||
upload
|
||||
* Fix app version in settings dialog, General tab
|
||||
* Fix crash in FolderWizard when going offline
|
||||
* Shibboleth fixes
|
||||
* More specific error messages (file remove during upload, open
|
||||
local sync file)
|
||||
* Use QSet rather than QHash in SyncEngine (save memory)
|
||||
* Fix some memory leaks
|
||||
* Fix some thread race problems, ie. wait for neon thread to finish
|
||||
before the propagator is shut down
|
||||
* Fix a lot of issues and warnings found by Coverity
|
||||
* Fix Mac some settings dialog problems
|
||||
|
||||
|
||||
version 1.6.0 (release 2014-05-30 )
|
||||
* Minor GUI improvements
|
||||
* Qt5 compile issues fixed
|
||||
|
|
|
@ -1,44 +1,44 @@
|
|||
# Auto-generated - do not modify
|
||||
StrCpy $MUI_FINISHPAGE_SHOWREADME_TEXT_STRING "Mostrar les notes de versió"
|
||||
StrCpy $ConfirmEndProcess_MESSAGEBOX_TEXT "S'ha trobat el(s) procés ${APPLICATION_EXECUTABLE} que s'ha d'aturar.$\nVoleu que l'instal·lador l'aturi?"
|
||||
StrCpy $ConfirmEndProcess_KILLING_PROCESSES_TEXT "S'estan matant els processos ${APPLICATION_EXECUTABLE}."
|
||||
StrCpy $ConfirmEndProcess_KILL_NOT_FOUND_TEXT "Procés per matar no trobat!"
|
||||
StrCpy $PageReinstall_NEW_Field_1 "Una versió anterior de ${APPLICATION_NAME} està instal·lada en el vostre sistema. Es recomana desinstal·lar la versió actual abans d'instal·lar. Seleccioneu l'operació que desitjeu realitzar i feu clic a Següent per continuar."
|
||||
StrCpy $PageReinstall_NEW_Field_2 "Desinstal·lar abans d'instal·lar"
|
||||
StrCpy $PageReinstall_NEW_Field_3 "No instal·lar"
|
||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_TITLE "Ja instal·lat"
|
||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_SUBTITLE "Trieu la manera com voleu instal·lar ${APPLICATION_NAME}."
|
||||
StrCpy $PageReinstall_OLD_Field_1 "Una versió més recent de ${APPLICATION_NAME} ja està instal.lada!! No es recomana instal.lar una versió més antiga. Si realment voleu instal.lar una versió més antiga, és millor primer desinstal.lar la versió actual. Seleccioni l'operació que desitjeu realitzar i feu clic a Següent per a continuar."
|
||||
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} ja està instal.lat.↩\nSeleccioneu l'operació que desitjeu realitzar i feu clic a Següent per continuar."
|
||||
StrCpy $PageReinstall_SAME_Field_2 "Afegir/Reinstal.lar components"
|
||||
StrCpy $PageReinstall_SAME_Field_3 "Desinstal.lar ${APPLICATION_NAME}"
|
||||
StrCpy $UNINSTALLER_APPDATA_TITLE "Desinstal.lar ${APPLICATION_NAME}"
|
||||
StrCpy $PageReinstall_SAME_MUI_HEADER_TEXT_SUBTITLE "Escolliu l'opció de manteniment per executar-ho."
|
||||
StrCpy $SEC_APPLICATION_DETAILS "Instal·lant ${APPLICATION_NAME} essencial."
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_SECTION "Accés directe del programa al menú d'inici"
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "Afegint la drecera per ${APPLICATION_NAME} al menú d'inici."
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_SECTION "Drecera a l'escriptori"
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_DetailPrint "Creant les dreceres a l'escriptori"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_SECTION "Drecera d'inici ràpid"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_DetailPrint "Creant la drecera per l'inici ràpid"
|
||||
StrCpy $OPTION_SECTION_SC_APPLICATION_Desc "${APPLICATION_NAME} essencial."
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_Desc "Drecera ${APPLICATION_NAME}."
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_Desc "Drecera a l'escrptori per ${APPLICATION_NAME}."
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_Desc "Drecera d'inici ràpid per ${APPLICATION_NAME}."
|
||||
StrCpy $UNINSTALLER_APPDATA_SUBTITLE "Esborra la carpeta de dades de ${APPLICATION_NAME} del vostre equip."
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_1 "Voleu esborrar la carpeta de dades de ${APPLICATION_NAME}?"
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_2 "Deixeu-ho sense marcar per mantenir la carpeta de dades per un ús posterior o marqueu-ho per esborrar la carpeta de dades."
|
||||
StrCpy $UNINSTALLER_APPDATA_CHECKBOX "Sí, esborra la carpeta de dades."
|
||||
StrCpy $UNINSTALLER_FILE_Detail "Escrivint el desinstal·lador"
|
||||
StrCpy $UNINSTALLER_REGISTRY_Detail "Escrivint les claus del registre de l'instal·lador"
|
||||
StrCpy $UNINSTALLER_FINISHED_Detail "Acabat"
|
||||
StrCpy $UNINSTALL_MESSAGEBOX "No sembla que ${APPLICATION_NAME} estigui instal·lat en la carpeta '$INSTDIR'.$\n$\nContinuo igualment (no recomanat)?"
|
||||
StrCpy $UNINSTALL_ABORT "La desinstal·lació s'ha cancel·lat."
|
||||
StrCpy $INIT_NO_QUICK_LAUNCH "Drecera d'inici ràpid (N/A)"
|
||||
StrCpy $INIT_NO_DESKTOP "Drecera de l'escrpitori (sobreescriu l'existent)"
|
||||
StrCpy $UAC_ERROR_ELEVATE "No es pot elevar, error:"
|
||||
StrCpy $UAC_INSTALLER_REQUIRE_ADMIN "Aquest instal·lador requereix accés d'administrador, intenteu-ho de nou"
|
||||
StrCpy $INIT_INSTALLER_RUNNING "L'instal·lador ja s'està executant."
|
||||
StrCpy $UAC_UNINSTALLER_REQUIRE_ADMIN "Aquest desinstal·lador requereix accés d'administrador, intenteu-ho de nou."
|
||||
StrCpy $INIT_UNINSTALLER_RUNNING "El desinstal·lador ja s'està executant."
|
||||
StrCpy $SectionGroup_Shortcuts "Dreceres"
|
||||
StrCpy $ConfirmEndProcess_MESSAGEBOX_TEXT "Found ${APPLICATION_EXECUTABLE} process(s) which need to be stopped.$\nDo you want the installer to stop these for you?"
|
||||
StrCpy $ConfirmEndProcess_KILLING_PROCESSES_TEXT "Killing ${APPLICATION_EXECUTABLE} processes."
|
||||
StrCpy $PageReinstall_OLD_Field_1 "A newer version of ${APPLICATION_NAME} is already installed! It is not recommended that you install an older version. If you really want to install this older version, it is better to uninstall the current version first. Select the operation you want to perform and click Next to continue."
|
||||
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} is already installed.\r\nSelect the operation you want to perform and click Next to continue."
|
||||
StrCpy $PageReinstall_SAME_Field_2 "Add/Reinstall components"
|
||||
StrCpy $PageReinstall_SAME_Field_3 "Uninstall ${APPLICATION_NAME}"
|
||||
StrCpy $UNINSTALLER_APPDATA_TITLE "Uninstall ${APPLICATION_NAME}"
|
||||
StrCpy $PageReinstall_SAME_MUI_HEADER_TEXT_SUBTITLE "Choose the maintenance option to perform."
|
||||
StrCpy $SEC_APPLICATION_DETAILS "Installing ${APPLICATION_NAME} essentials."
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_SECTION "Start Menu Program Shortcut"
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "Adding shortcut for ${APPLICATION_NAME} to the Start Menu."
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_SECTION "Desktop Shortcut"
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_DetailPrint "Creating Desktop Shortcuts"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_SECTION "Quick Launch Shortcut"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_DetailPrint "Creating Quick Launch Shortcut"
|
||||
StrCpy $OPTION_SECTION_SC_APPLICATION_Desc "${APPLICATION_NAME} essentials."
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_Desc "${APPLICATION_NAME} shortcut."
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_Desc "Desktop shortcut for ${APPLICATION_NAME}."
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_Desc "Quick Launch shortcut for ${APPLICATION_NAME}."
|
||||
StrCpy $UNINSTALLER_APPDATA_SUBTITLE "Remove ${APPLICATION_NAME}'s data folder from your computer."
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_1 "Do you want to delete ${APPLICATION_NAME}'s data folder?"
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_2 "Leave unchecked to keep the data folder for later use or check to delete the data folder."
|
||||
StrCpy $UNINSTALLER_APPDATA_CHECKBOX "Yes, delete this data folder."
|
||||
StrCpy $UNINSTALLER_FILE_Detail "Writing Uninstaller"
|
||||
StrCpy $UNINSTALLER_REGISTRY_Detail "Writing Installer Registry Keys"
|
||||
StrCpy $UNINSTALL_MESSAGEBOX "It does not appear that ${APPLICATION_NAME} is installed in the directory '$INSTDIR'.$\r$\nContinue anyway (not recommended)?"
|
||||
StrCpy $UNINSTALL_ABORT "Uninstall aborted by user"
|
||||
StrCpy $INIT_NO_QUICK_LAUNCH "Quick Launch Shortcut (N/A)"
|
||||
StrCpy $INIT_NO_DESKTOP "Desktop Shortcut (overwrites existing)"
|
||||
StrCpy $UAC_ERROR_ELEVATE "Unable to elevate, error:"
|
||||
StrCpy $UAC_INSTALLER_REQUIRE_ADMIN "This installer requires admin access, try again"
|
||||
StrCpy $INIT_INSTALLER_RUNNING "The installer is already running."
|
||||
StrCpy $UAC_UNINSTALLER_REQUIRE_ADMIN "This uninstaller requires admin access, try again"
|
||||
StrCpy $INIT_UNINSTALLER_RUNNING "The uninstaller is already running."
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# Auto-generated - do not modify
|
||||
StrCpy $MUI_FINISHPAGE_SHOWREADME_TEXT_STRING "查看版本日志"
|
||||
StrCpy $ConfirmEndProcess_MESSAGEBOX_TEXT "有 ${APPLICATION_EXECUTABLE} 项进程需要关闭。$\n您想让安装程序关闭这些进程吗?"
|
||||
StrCpy $ConfirmEndProcess_KILLING_PROCESSES_TEXT "杀死${APPLICATION_EXECUTABLE}进程。"
|
||||
StrCpy $ConfirmEndProcess_KILL_NOT_FOUND_TEXT "未找到要杀死的进程!"
|
||||
StrCpy $PageReinstall_NEW_Field_1 "您的系统已经安装${APPLICATION_NAME}较老版本。建议安装前卸载当前版本。选择将要执行的操作,点击下一步继续。"
|
||||
|
@ -7,11 +8,15 @@ StrCpy $PageReinstall_NEW_Field_2 "在安装前先卸载"
|
|||
StrCpy $PageReinstall_NEW_Field_3 "不要卸载"
|
||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_TITLE "已经安装"
|
||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_SUBTITLE "选择如何安装${APPLICATION_NAME}。"
|
||||
StrCpy $PageReinstall_OLD_Field_1 "较新版本的 ${APPLICATION_NAME} 已经安装!安装较旧版本的程序是不推荐的。如果您希望继续安装较旧版本,建议先卸载较新版本。选择您想要执行的操作并点击下一步以继续。"
|
||||
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} 已经安装。\n请选择想要执行的操作并点击下一步。"
|
||||
StrCpy $PageReinstall_SAME_Field_2 "增加/重装组件"
|
||||
StrCpy $PageReinstall_SAME_Field_3 "卸载${APPLICATION_NAME}"
|
||||
StrCpy $UNINSTALLER_APPDATA_TITLE "卸载${APPLICATION_NAME}"
|
||||
StrCpy $PageReinstall_SAME_MUI_HEADER_TEXT_SUBTITLE "选择需要执行的维护选项。"
|
||||
StrCpy $SEC_APPLICATION_DETAILS "安装${APPLICATION_NAME}基本组件。"
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_SECTION "开始菜单程序快捷方式"
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "添加 ${APPLICATION_NAME} 快捷方式到开始菜单。"
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_SECTION "桌面快捷方式"
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_DetailPrint "创建桌面快捷方式"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_SECTION "快速启动栏快捷方式"
|
||||
|
@ -20,25 +25,20 @@ StrCpy $OPTION_SECTION_SC_APPLICATION_Desc "${APPLICATION_NAME}基本组件。"
|
|||
StrCpy $OPTION_SECTION_SC_START_MENU_Desc "${APPLICATION_NAME}快捷方式。"
|
||||
StrCpy $OPTION_SECTION_SC_DESKTOP_Desc "${APPLICATION_NAME}桌面快捷方式。"
|
||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_Desc "${APPLICATION_NAME}快速启动栏快捷方式。"
|
||||
StrCpy $UNINSTALLER_APPDATA_SUBTITLE "从电脑中移除 ${APPLICATION_NAME} 数据文件夹。"
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_1 "移除 ${APPLICATION_NAME} 数据文件夹?"
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_2 "选择以删除数据文件夹,不选择以保留数据文件夹内容供后续使用。"
|
||||
StrCpy $UNINSTALLER_APPDATA_CHECKBOX "删除数据文件。"
|
||||
StrCpy $UNINSTALLER_FILE_Detail "覆盖卸载器"
|
||||
StrCpy $UNINSTALLER_REGISTRY_Detail "正在写入注册表"
|
||||
StrCpy $UNINSTALLER_FINISHED_Detail "完成"
|
||||
StrCpy $UNINSTALL_MESSAGEBOX "${APPLICATION_NAME} 可能并没有安装在 $INSTDIR。$\n$\n仍然继续吗?(不推荐)"
|
||||
StrCpy $UNINSTALL_ABORT "用户取消了卸载"
|
||||
StrCpy $INIT_NO_QUICK_LAUNCH "快速启动栏快捷方式(N/A)"
|
||||
StrCpy $INIT_NO_DESKTOP "桌面快捷方式(覆盖)"
|
||||
StrCpy $UAC_ERROR_ELEVATE "无法获得权限,错误:"
|
||||
StrCpy $UAC_INSTALLER_REQUIRE_ADMIN "安装程序需要管理员权限,请重试"
|
||||
StrCpy $INIT_INSTALLER_RUNNING "安装程序已经运行。"
|
||||
StrCpy $UAC_UNINSTALLER_REQUIRE_ADMIN "卸载程序需要管理员权限,请重试"
|
||||
StrCpy $INIT_UNINSTALLER_RUNNING "卸载程序已经运行。"
|
||||
StrCpy $SectionGroup_Shortcuts "快捷方式"
|
||||
StrCpy $ConfirmEndProcess_MESSAGEBOX_TEXT "Found ${APPLICATION_EXECUTABLE} process(s) which need to be stopped.$\nDo you want the installer to stop these for you?"
|
||||
StrCpy $PageReinstall_OLD_Field_1 "A newer version of ${APPLICATION_NAME} is already installed! It is not recommended that you install an older version. If you really want to install this older version, it is better to uninstall the current version first. Select the operation you want to perform and click Next to continue."
|
||||
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} is already installed.\r\nSelect the operation you want to perform and click Next to continue."
|
||||
StrCpy $PageReinstall_SAME_MUI_HEADER_TEXT_SUBTITLE "Choose the maintenance option to perform."
|
||||
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "Adding shortcut for ${APPLICATION_NAME} to the Start Menu."
|
||||
StrCpy $UNINSTALLER_APPDATA_SUBTITLE "Remove ${APPLICATION_NAME}'s data folder from your computer."
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_1 "Do you want to delete ${APPLICATION_NAME}'s data folder?"
|
||||
StrCpy $UNINSTALLER_APPDATA_LABEL_2 "Leave unchecked to keep the data folder for later use or check to delete the data folder."
|
||||
StrCpy $UNINSTALLER_REGISTRY_Detail "Writing Installer Registry Keys"
|
||||
StrCpy $UNINSTALL_MESSAGEBOX "It does not appear that ${APPLICATION_NAME} is installed in the directory '$INSTDIR'.$\r$\nContinue anyway (not recommended)?"
|
||||
StrCpy $UNINSTALL_ABORT "Uninstall aborted by user"
|
||||
StrCpy $UAC_ERROR_ELEVATE "Unable to elevate, error:"
|
||||
StrCpy $UAC_INSTALLER_REQUIRE_ADMIN "This installer requires admin access, try again"
|
||||
StrCpy $INIT_INSTALLER_RUNNING "The installer is already running."
|
||||
StrCpy $UAC_UNINSTALLER_REQUIRE_ADMIN "This uninstaller requires admin access, try again"
|
||||
StrCpy $INIT_UNINSTALLER_RUNNING "The uninstaller is already running."
|
||||
|
|
|
@ -13,7 +13,7 @@ if (${CMAKE_C_COMPILER_ID} MATCHES "(GNU|Clang)")
|
|||
if (NOT CSYNC_STATIC_COMPILE_DIR)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -pedantic -pedantic-errors")
|
||||
endif()
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wshadow -Wmissing-prototypes -Wdeclaration-after-statement")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wshadow -Wmissing-prototypes")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wunused -Wfloat-equal -Wpointer-arith -Wwrite-strings -Wformat-security")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wmissing-format-attribute")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wmissing-format-attribute -D_GNU_SOURCE")
|
||||
|
|
|
@ -111,8 +111,8 @@ ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll"
|
|||
!define MUI_HEADERIMAGE
|
||||
!define MUI_HEADERIMAGE_BITMAP ${WIN_SETUP_BITMAP_PATH}/page_header.bmp
|
||||
!define MUI_COMPONENTSPAGE_SMALLDESC
|
||||
!define MUI_FINISHPAGE_LINK "www.${APPLICATION_DOMAIN}"
|
||||
!define MUI_FINISHPAGE_LINK_LOCATION "http://www.${APPLICATION_DOMAIN}"
|
||||
!define MUI_FINISHPAGE_LINK "${APPLICATION_DOMAIN}"
|
||||
!define MUI_FINISHPAGE_LINK_LOCATION "http://${APPLICATION_DOMAIN}"
|
||||
!define MUI_FINISHPAGE_NOREBOOTSUPPORT
|
||||
!ifdef OPTION_FINISHPAGE_RELEASE_NOTES
|
||||
!define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
|
||||
|
@ -370,6 +370,7 @@ Section "${APPLICATION_NAME}" SEC_APPLICATION
|
|||
;Main executable & csync
|
||||
File "${BUILD_PATH}\bin\${APPLICATION_EXECUTABLE}"
|
||||
File "${BUILD_PATH}\bin\${APPLICATION_CMD_EXECUTABLE}"
|
||||
File "${BUILD_PATH}\bin\socketapiclient.exe"
|
||||
File "${BUILD_PATH}\src\lib${APPLICATION_SHORTNAME}sync.dll"
|
||||
File "${BUILD_PATH}\csync\src\libocsync.dll"
|
||||
|
||||
|
@ -413,15 +414,14 @@ Section "${APPLICATION_NAME}" SEC_APPLICATION
|
|||
File "${QT_DLL_PATH}\Qt5Xml.dll"
|
||||
|
||||
;Qt deps
|
||||
File "${MING_BIN}\libpng15-15.dll"
|
||||
File "${MING_BIN}\icudata51.dll"
|
||||
File "${MING_BIN}\icui18n51.dll"
|
||||
File "${MING_BIN}\icuuc51.dll"
|
||||
File "${MING_BIN}\libpng16-16.dll"
|
||||
File "${MING_BIN}\icudata53.dll"
|
||||
File "${MING_BIN}\icui18n53.dll"
|
||||
File "${MING_BIN}\icuuc53.dll"
|
||||
File "${MING_BIN}\libEGL.dll"
|
||||
File "${MING_BIN}\libGLESv2.dll"
|
||||
File "${MING_BIN}\libjpeg-8.dll"
|
||||
File "${MING_BIN}\libpcre16-0.dll"
|
||||
File "${MING_BIN}\libpng15-15.dll"
|
||||
File "${MING_BIN}\libproxy.dll"
|
||||
File "${MING_BIN}\libqt5keychain.dll"
|
||||
File "${MING_BIN}\libsqlite3-0.dll"
|
||||
|
@ -448,6 +448,7 @@ Section "${APPLICATION_NAME}" SEC_APPLICATION
|
|||
;MinGW stuff
|
||||
File "${MING_BIN}\libgcc_s_sjlj-1.dll"
|
||||
File "${MING_BIN}\libstdc++-6.dll"
|
||||
File "${MING_BIN}\libwinpthread-1.dll"
|
||||
|
||||
; CSync configs
|
||||
File "${SOURCE_PATH}/sync-exclude.lst"
|
||||
|
|
|
@ -148,6 +148,8 @@ if(NOT Qt5Core_FOUND)
|
|||
|
||||
include( ${QT_USE_FILE} )
|
||||
endmacro()
|
||||
|
||||
add_definitions("-DQ_DECL_OVERRIDE=override")
|
||||
endif()
|
||||
|
||||
if( Qt5Core_DIR )
|
||||
|
|
|
@ -6,9 +6,11 @@ if(CMAKE_COMPILER_IS_GNUCXX)
|
|||
else(GCC_VERSION VERSION_GREATER 4.8 OR GCC_VERSION VERSION_EQUAL 4.8)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic -Wno-long-long")
|
||||
endif(GCC_VERSION VERSION_GREATER 4.8 OR GCC_VERSION VERSION_EQUAL 4.8)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
|
||||
endif(CMAKE_COMPILER_IS_GNUCXX)
|
||||
if(CMAKE_CXX_COMPILER MATCHES "clang")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic -Wno-long-long")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
|
||||
endif(CMAKE_CXX_COMPILER MATCHES "clang")
|
||||
# TODO: handle msvc compilers warnings?
|
||||
|
||||
|
|
|
@ -240,11 +240,6 @@ int csync_update(CSYNC *ctx) {
|
|||
c_secdiff(finish, start), c_rbtree_size(ctx->local.tree));
|
||||
csync_memstat_check();
|
||||
|
||||
if (rc < 0) {
|
||||
ctx->status_code = CSYNC_STATUS_TREE_ERROR;
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* update detection for remote replica */
|
||||
csync_gettime(&start);
|
||||
ctx->current = REMOTE_REPLICA;
|
||||
|
|
|
@ -235,6 +235,7 @@ CSYNC_EXCLUDE_TYPE csync_excluded(CSYNC *ctx, const char *path, int filetype) {
|
|||
|
||||
type = CSYNC_FILE_EXCLUDE_LIST;
|
||||
if (strlen(pattern) < 1) {
|
||||
SAFE_FREE(pattern_stored);
|
||||
continue;
|
||||
}
|
||||
/* Ecludes starting with ']' means it can be cleanup */
|
||||
|
@ -270,6 +271,9 @@ CSYNC_EXCLUDE_TYPE csync_excluded(CSYNC *ctx, const char *path, int filetype) {
|
|||
|
||||
if (bname == NULL || dname == NULL) {
|
||||
match = CSYNC_NOT_EXCLUDED;
|
||||
SAFE_FREE(bname);
|
||||
SAFE_FREE(dname);
|
||||
SAFE_FREE(pattern_stored);
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
|
|
@ -567,7 +567,7 @@ static struct listdir_context *fetch_resource_list(csync_owncloud_ctx_t *ctx, co
|
|||
ret = NE_CONNECT;
|
||||
set_error_message(ctx, req_status->reason_phrase);
|
||||
}
|
||||
DEBUG_WEBDAV("Simple propfind result code %d.", req_status->code);
|
||||
DEBUG_WEBDAV("Simple propfind result code %d.", req_status ? req_status->code : -1);
|
||||
} else {
|
||||
if( ret == NE_ERROR && req_status->code == 404) {
|
||||
errno = ENOENT;
|
||||
|
|
|
@ -127,7 +127,7 @@ static const ne_propname ls_props[] = {
|
|||
{ "http://owncloud.org/ns", "id"},
|
||||
{ "http://owncloud.org/ns", "dDU"},
|
||||
{ "http://owncloud.org/ns", "dDC"},
|
||||
{ "http://owncloud.org/ns", "perm"},
|
||||
{ "http://owncloud.org/ns", "permissions"},
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
|
|
|
@ -171,13 +171,12 @@ static void propfind_results_recursive_callback(void *userdata,
|
|||
}
|
||||
|
||||
/* DEBUG_WEBDAV("results_recursive Added child %s to collection %s", newres->uri, element->self->uri); */
|
||||
} else {
|
||||
/* DEBUG_WEBDAV("results_recursive No parent %s found for child %s", parentPath, newres->uri); */
|
||||
resource_free(newres);
|
||||
newres = NULL;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
resource_free(newres);
|
||||
newres = NULL;
|
||||
}
|
||||
|
||||
void fetch_resource_list_recursive(csync_owncloud_ctx_t *ctx, const char *uri, const char *curi)
|
||||
|
|
|
@ -318,7 +318,7 @@ void resourceToFileStat(csync_vio_file_stat_t *lfs, struct resource *res )
|
|||
lfs->directDownloadCookies = c_strdup(res->directDownloadCookies);
|
||||
}
|
||||
if (strlen(res->remotePerm) > 0) {
|
||||
lfs->fields = CSYNC_VIO_FILE_STAT_FIELDS_PERM;
|
||||
lfs->fields |= CSYNC_VIO_FILE_STAT_FIELDS_PERM;
|
||||
strncpy(lfs->remotePerm, res->remotePerm, sizeof(lfs->remotePerm));
|
||||
}
|
||||
}
|
||||
|
@ -373,15 +373,15 @@ void fill_webdav_properties_into_resource(struct resource* newres, const ne_prop
|
|||
if (directDownloadCookies) {
|
||||
newres->directDownloadCookies = c_strdup(directDownloadCookies);
|
||||
}
|
||||
if (perm && strlen(perm) < sizeof(newres->remotePerm)) {
|
||||
strncpy(newres->remotePerm, perm, sizeof(newres->remotePerm));
|
||||
} else if (perm && strlen(perm) == 0) {
|
||||
if (perm && !perm[0]) {
|
||||
// special meaning for our code: server returned permissions but are empty
|
||||
// meaning only reading is allowed for this resource
|
||||
newres->remotePerm[0] = ' ';
|
||||
// see _csync_detect_update()
|
||||
} else if (perm && strlen(perm) < sizeof(newres->remotePerm)) {
|
||||
strncpy(newres->remotePerm, perm, sizeof(newres->remotePerm));
|
||||
} else {
|
||||
// old server, keep NULL in newres->remotePerm
|
||||
// old server, keep newres->remotePerm empty
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -184,6 +184,7 @@ static int _csync_merge_algorithm_visitor(void *obj, void *data) {
|
|||
csync_vio_set_file_id( other->file_id, cur->file_id );
|
||||
}
|
||||
other->inode = cur->inode;
|
||||
other->should_update_etag = true;
|
||||
cur->instruction = CSYNC_INSTRUCTION_NONE;
|
||||
} else if (other->instruction == CSYNC_INSTRUCTION_REMOVE) {
|
||||
other->instruction = CSYNC_INSTRUCTION_RENAME;
|
||||
|
@ -193,6 +194,7 @@ static int _csync_merge_algorithm_visitor(void *obj, void *data) {
|
|||
csync_vio_set_file_id( other->file_id, cur->file_id );
|
||||
}
|
||||
other->inode = cur->inode;
|
||||
other->should_update_etag = true;
|
||||
cur->instruction = CSYNC_INSTRUCTION_NONE;
|
||||
} else if (other->instruction == CSYNC_INSTRUCTION_NEW) {
|
||||
CSYNC_LOG(CSYNC_LOG_PRIORITY_TRACE, "OOOO=> NEW detected in other tree!");
|
||||
|
@ -238,8 +240,8 @@ static int _csync_merge_algorithm_visitor(void *obj, void *data) {
|
|||
/* file on other replica is changed or new */
|
||||
case CSYNC_INSTRUCTION_NEW:
|
||||
case CSYNC_INSTRUCTION_EVAL:
|
||||
if (other->type == CSYNC_VIO_FILE_TYPE_DIRECTORY &&
|
||||
cur->type == CSYNC_VIO_FILE_TYPE_DIRECTORY) {
|
||||
if (other->type == CSYNC_FTW_TYPE_DIR &&
|
||||
cur->type == CSYNC_FTW_TYPE_DIR) {
|
||||
is_equal_files = (other->modtime == cur->modtime);
|
||||
} else {
|
||||
is_equal_files = ((other->size == cur->size) && (other->modtime == cur->modtime));
|
||||
|
|
|
@ -133,6 +133,8 @@ static int _csync_statedb_check(const char *statedb) {
|
|||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
close(fd);
|
||||
}
|
||||
/* if it comes here, the database is broken and should be recreated. */
|
||||
_tunlink(wstatedb);
|
||||
|
@ -314,10 +316,8 @@ static int _csync_file_stat_from_metadata_table( csync_file_stat_t **st, sqlite3
|
|||
if(column_count > 11 && sqlite3_column_text(stmt,11)) {
|
||||
strncpy((*st)->remotePerm,
|
||||
(char*) sqlite3_column_text(stmt, 11),
|
||||
sizeof((*st)->remotePerm));
|
||||
REMOTE_PERM_BUF_SIZE);
|
||||
}
|
||||
CSYNC_LOG(CSYNC_LOG_PRIORITY_ERROR, "%s %s",sqlite3_column_text(stmt, 10),sqlite3_column_text(stmt, 11) );
|
||||
|
||||
}
|
||||
}
|
||||
return rc;
|
||||
|
|
|
@ -254,38 +254,30 @@ static int _csync_detect_update(CSYNC *ctx, const char *file,
|
|||
st->instruction = CSYNC_INSTRUCTION_EVAL;
|
||||
goto out;
|
||||
}
|
||||
bool metadata_differ = (ctx->current == REMOTE_REPLICA && (!c_streq(fs->file_id, tmp->file_id)
|
||||
|| !c_streq(fs->remotePerm, tmp->remotePerm)))
|
||||
|| (ctx->current == LOCAL_REPLICA && fs->inode != tmp->inode);
|
||||
if (type == CSYNC_FTW_TYPE_DIR && ctx->current == REMOTE_REPLICA
|
||||
&& c_streq(fs->file_id, tmp->file_id) && !ctx->read_from_db_disabled) {
|
||||
&& !metadata_differ && !ctx->read_from_db_disabled) {
|
||||
/* If both etag and file id are equal for a directory, read all contents from
|
||||
* the database.
|
||||
* The comparison of file id ensure that we fetch all the file id when upgrading from
|
||||
* owncloud 5 to owncloud 6.
|
||||
* The metadata comparison ensure that we fetch all the file id or permission when
|
||||
* upgrading owncloud
|
||||
*/
|
||||
CSYNC_LOG(CSYNC_LOG_PRIORITY_TRACE, "Reading from database: %s", path);
|
||||
ctx->remote.read_from_db = true;
|
||||
}
|
||||
if (ctx->current == REMOTE_REPLICA
|
||||
// DB perm; true for NULL or empty (on update)
|
||||
&& strlen(tmp->remotePerm) == 0
|
||||
// remote perm (even if remote perm empty it will be ' ' see fill_webdav_properties_into_resource
|
||||
&& strlen(fs->remotePerm) > 0)
|
||||
{
|
||||
/* remotePerm received from server but none in DB.
|
||||
* Which means we need to update the DB.
|
||||
* (upgrade from owncloud x to owncloud 7 for instence) */
|
||||
st->should_update_etag = true; // write to DB after PROPFIND
|
||||
ctx->remote.read_from_db = false; // get dirs via PROPFIND
|
||||
|
||||
}
|
||||
if (!c_streq(fs->file_id, tmp->file_id) && ctx->current == REMOTE_REPLICA) {
|
||||
/* file id has changed. Which means we need to update the DB.
|
||||
* (upgrade from owncloud 5 to owncloud 6 for instence) */
|
||||
if (metadata_differ) {
|
||||
/* file id or permissions has changed. Which means we need to update them in the DB. */
|
||||
st->should_update_etag = true;
|
||||
}
|
||||
st->instruction = CSYNC_INSTRUCTION_NONE;
|
||||
} else {
|
||||
enum csync_vio_file_type_e tmp_vio_type = CSYNC_VIO_FILE_TYPE_UNKNOWN;
|
||||
|
||||
/* tmp might point to malloc mem, so free it here before reusing tmp */
|
||||
SAFE_FREE(tmp);
|
||||
|
||||
/* check if it's a file and has been renamed */
|
||||
if (ctx->current == LOCAL_REPLICA) {
|
||||
CSYNC_LOG(CSYNC_LOG_PRIORITY_TRACE, "Checking for rename based on inode # %" PRId64 "", (uint64_t) fs->inode);
|
||||
|
@ -390,7 +382,7 @@ out:
|
|||
st->directDownloadCookies = c_strdup(fs->directDownloadCookies);
|
||||
}
|
||||
if (fs->fields & CSYNC_VIO_FILE_STAT_FIELDS_PERM) {
|
||||
strncpy(st->remotePerm, fs->remotePerm, sizeof(st->remotePerm));
|
||||
strncpy(st->remotePerm, fs->remotePerm, REMOTE_PERM_BUF_SIZE);
|
||||
}
|
||||
|
||||
fastout: /* target if the file information is read from database into st */
|
||||
|
@ -700,8 +692,7 @@ int csync_ftw(CSYNC *ctx, const char *uri, csync_walker_fn fn,
|
|||
|
||||
if (flag == CSYNC_FTW_FLAG_DIR && ctx->current_fs
|
||||
&& (ctx->current_fs->instruction == CSYNC_INSTRUCTION_EVAL ||
|
||||
ctx->current_fs->instruction == CSYNC_INSTRUCTION_NEW ||
|
||||
ctx->current_fs->instruction == CSYNC_INSTRUCTION_EVAL_RENAME)) {
|
||||
ctx->current_fs->instruction == CSYNC_INSTRUCTION_NEW)) {
|
||||
ctx->current_fs->should_update_etag = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -113,12 +113,12 @@ void csync_win32_set_file_hidden( const char *file, bool h ) {
|
|||
fileName = c_utf8_to_locale( file );
|
||||
dwAttrs = GetFileAttributesW(fileName);
|
||||
|
||||
if (dwAttrs==INVALID_FILE_ATTRIBUTES) return;
|
||||
|
||||
if (h && !(dwAttrs & FILE_ATTRIBUTE_HIDDEN)) {
|
||||
SetFileAttributesW(fileName, dwAttrs | FILE_ATTRIBUTE_HIDDEN );
|
||||
} else if (!h && (dwAttrs & FILE_ATTRIBUTE_HIDDEN)) {
|
||||
SetFileAttributesW(fileName, dwAttrs & ~FILE_ATTRIBUTE_HIDDEN );
|
||||
if (dwAttrs != INVALID_FILE_ATTRIBUTES) {
|
||||
if (h && !(dwAttrs & FILE_ATTRIBUTE_HIDDEN)) {
|
||||
SetFileAttributesW(fileName, dwAttrs | FILE_ATTRIBUTE_HIDDEN );
|
||||
} else if (!h && (dwAttrs & FILE_ATTRIBUTE_HIDDEN)) {
|
||||
SetFileAttributesW(fileName, dwAttrs & ~FILE_ATTRIBUTE_HIDDEN );
|
||||
}
|
||||
}
|
||||
|
||||
c_free_locale_string(fileName);
|
||||
|
|
|
@ -204,9 +204,9 @@ void hbf_free_transfer( hbf_transfer_t *transfer ) {
|
|||
|
||||
for( cnt = 0; cnt < transfer->block_cnt; cnt++ ) {
|
||||
hbf_block_t *block = transfer->block_arr[cnt];
|
||||
if( !block ) continue;
|
||||
if( block->http_error_msg ) free( block->http_error_msg );
|
||||
if( block->etag ) free( block->etag );
|
||||
if( block ) free(block);
|
||||
}
|
||||
free( transfer->block_arr );
|
||||
free( transfer->url );
|
||||
|
@ -536,8 +536,8 @@ Hbf_State hbf_transfer( ne_session *session, hbf_transfer_t *transfer, const cha
|
|||
} else {
|
||||
state = HBF_MEMORY_FAIL;
|
||||
}
|
||||
free( transfer_url );
|
||||
}
|
||||
free( transfer_url );
|
||||
}
|
||||
|
||||
/* do the source file validation finally (again). */
|
||||
|
|
|
@ -135,7 +135,8 @@ int c_utimes(const char *uri, const struct timeval *times) {
|
|||
if(!SetFileTime(hFile, NULL, &LastAccessTime, &LastModificationTime)) {
|
||||
//can this happen?
|
||||
errno=ENOENT;
|
||||
CloseHandle(hFile);
|
||||
CloseHandle(hFile);
|
||||
c_free_locale_string(wuri);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
|
|
@ -257,6 +257,7 @@ int csync_vio_local_stat(const char *uri, csync_vio_file_stat_t *buf) {
|
|||
buf->fields |= CSYNC_VIO_FILE_STAT_FIELDS_CTIME;
|
||||
}
|
||||
|
||||
c_free_locale_string(wuri);
|
||||
CloseHandle(h);
|
||||
|
||||
return 0;
|
||||
|
|
|
@ -38,7 +38,6 @@ static void check_csync_destroy_null(void **state)
|
|||
static void check_csync_create(void **state)
|
||||
{
|
||||
CSYNC *csync;
|
||||
char confdir[1024] = {0};
|
||||
int rc;
|
||||
|
||||
(void) state; /* unused */
|
||||
|
|
|
@ -34,6 +34,7 @@ use LWP::UserAgent;
|
|||
use LWP::Protocol::https;
|
||||
use HTTP::Request::Common qw( POST GET DELETE );
|
||||
use File::Basename;
|
||||
use IO::Handle;
|
||||
|
||||
use Encode qw(from_to);
|
||||
use utf8;
|
||||
|
@ -577,7 +578,7 @@ sub createLocalFile( $$ )
|
|||
my $minimum = 32;
|
||||
my $range = 96;
|
||||
|
||||
for (my $bytes = 0; $bytes < $size; $bytes += 4) {
|
||||
for (my $bytes = 0; $bytes < $size-1; $bytes += 4) {
|
||||
my $rand = int(rand($range ** 4));
|
||||
my $string = '';
|
||||
for (1..4) {
|
||||
|
@ -587,6 +588,9 @@ sub createLocalFile( $$ )
|
|||
print FILE $string;
|
||||
$md5->add($string);
|
||||
}
|
||||
my $s = "\n";
|
||||
print FILE $s;
|
||||
$md5->add($s);
|
||||
close FILE;
|
||||
return $md5->hexdigest;
|
||||
}
|
||||
|
|
|
@ -123,8 +123,8 @@ assertLocalAndRemoteDir( '', 0);
|
|||
|
||||
# The previous sync should have updated the etags, and this should NOT be a conflict
|
||||
printInfo( "Update the file again");
|
||||
system("echo more data >> " . localDir() . "remoteToLocal1/kernelcrash.txt");
|
||||
system("echo corruption >> " . localDir() . "remoteToLocal1/kraft_logo.gif");
|
||||
createLocalFile( localDir() . "remoteToLocal1/kernelcrash.txt", 2136 );
|
||||
createLocalFile( localDir() . "remoteToLocal1/kraft_logo.gif", 2332 );
|
||||
csync( );
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
|
|
@ -185,12 +185,35 @@ assertLocalAndRemoteDir( 'remoteToLocal1', 1);
|
|||
printInfo("Move a file from the server");
|
||||
$inode = getInode('remoteToLocal1/rtl2/kb1_local_gone.jpg');
|
||||
moveRemoteFile( 'remoteToLocal1/rtl2/kb1_local_gone.jpg', 'remoteToLocal1/rtl2/kb1_local_gone2.jpg');
|
||||
|
||||
#also create a new directory localy for the next test
|
||||
mkdir( localDir().'superNewDir' );
|
||||
createLocalFile(localDir(). 'superNewDir/f1', 1234 );
|
||||
createLocalFile(localDir(). 'superNewDir/f2', 1324 );
|
||||
my $superNewDirInode = getInode('superNewDir');
|
||||
|
||||
|
||||
csync();
|
||||
assertLocalAndRemoteDir( 'remoteToLocal1', 1);
|
||||
assertLocalAndRemoteDir( '', 1);
|
||||
$inode2 = getInode('remoteToLocal1/rtl2/kb1_local_gone2.jpg');
|
||||
assert( $inode == $inode2, "Inode has changed 3!");
|
||||
|
||||
|
||||
printInfo("Move a newly created directory");
|
||||
moveRemoteFile('superNewDir', 'superNewDirRenamed');
|
||||
#also add new files in new directory
|
||||
createLocalFile(localDir(). 'superNewDir/f3' , 2456 );
|
||||
$inode = getInode('superNewDir/f3');
|
||||
|
||||
csync();
|
||||
assertLocalAndRemoteDir( '', 1);
|
||||
my $file = localDir() . 'superNewDir';
|
||||
assert( -e $file );
|
||||
|
||||
$inode2 = getInode('superNewDir/f3');
|
||||
assert( $inode == $inode2, "Inode of f3 changed");
|
||||
$inode2 = getInode('superNewDir');
|
||||
assert( $superNewDirInode == $inode2, "Inode of superNewDir changed");
|
||||
|
||||
cleanup();
|
||||
|
||||
|
|
|
@ -30,7 +30,6 @@ use ownCloud::Test;
|
|||
use strict;
|
||||
|
||||
print "Hello, this is t5, a tester for syncing of files in Shares\n";
|
||||
# stat error occours on windsows when the file is busy for example
|
||||
|
||||
initTesting();
|
||||
|
||||
|
|
|
@ -33,6 +33,34 @@ print "Hello, this is t6, a tester for csync with ownCloud.\n";
|
|||
|
||||
initTesting();
|
||||
|
||||
sub createPostUpdateScript()
|
||||
{
|
||||
my $srcFile = localDir()."BIG.file";
|
||||
my $cred = configValue("user") . ":" . configValue("passwd");
|
||||
my $cmd = "curl -T $srcFile -u $cred " . testDirUrl();
|
||||
my $script = "/tmp/post_update_script.sh";
|
||||
open SC, ">$script" || die("Can not create script file");
|
||||
print SC "#!/bin/bash\n";
|
||||
print SC "$cmd\n";
|
||||
close SC;
|
||||
chmod 0755, $script;
|
||||
|
||||
return $script;
|
||||
}
|
||||
|
||||
sub getETagFromJournal($)
|
||||
{
|
||||
my ($num) = @_;
|
||||
|
||||
my $sql = "sqlite3 " . localDir() . ".csync_journal.db \"SELECT md5 FROM metadata WHERE path='BIG.file';\"";
|
||||
open(my $fh, '-|', $sql) or die $!;
|
||||
my $etag = <$fh>;
|
||||
close $fh;
|
||||
print "$num etag: $etag";
|
||||
|
||||
return $etag;
|
||||
}
|
||||
|
||||
sub chunkFileTest( $$ )
|
||||
{
|
||||
my ($name, $size) = @_;
|
||||
|
@ -63,7 +91,27 @@ sub chunkFileTest( $$ )
|
|||
printInfo("Big file that needs chunking with default chunk size");
|
||||
chunkFileTest( "BIG.file", 23251233 );
|
||||
|
||||
# Set a custom chunk size in environment.
|
||||
printInfo("Update the existing file and trigger reupload");
|
||||
# change the existing file again -> update
|
||||
chunkFileTest( "BIG.file", 21762122 );
|
||||
|
||||
printInfo("Cause a precondition failed error");
|
||||
# Now overwrite the existing file to change it
|
||||
createLocalFile( localDir()."BIG.file", 21832199 );
|
||||
# and create a post update script
|
||||
my $script = createPostUpdateScript();
|
||||
$ENV{'OWNCLOUD_POST_UPDATE_SCRIPT'} = $script;
|
||||
|
||||
# Save the etag before the sync
|
||||
my $firstETag = getETagFromJournal('First');
|
||||
csync(); # Sync, which ends in a precondition failed error
|
||||
# get the etag again. It has to be unchanged because of the error.
|
||||
my $secondETag = getETagFromJournal('Second');
|
||||
assert( $firstETag eq $secondETag, "Different ETags, no precondition error." );
|
||||
|
||||
unlink($script);
|
||||
|
||||
# Set a custom chunk size in environment.
|
||||
my $ChunkSize = 1*1024*1024;
|
||||
$ENV{'OWNCLOUD_CHUNK_SIZE'} = $ChunkSize;
|
||||
|
||||
|
|
235
csync/tests/ownCloud/t7.pl
Executable file
|
@ -0,0 +1,235 @@
|
|||
#!/usr/bin/perl
|
||||
#
|
||||
# Test script for the ownCloud module of csync.
|
||||
# This script requires a running ownCloud instance accessible via HTTP.
|
||||
# It does quite some fancy tests and asserts the results.
|
||||
#
|
||||
# Copyright (C) by Klaas Freitag <freitag@owncloud.com>
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License as published by the Free Software Foundation; either
|
||||
# version 2.1 of the License, or (at your option) any later version.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
use lib ".";
|
||||
|
||||
use Carp::Assert;
|
||||
use File::Copy;
|
||||
use ownCloud::Test;
|
||||
|
||||
use strict;
|
||||
|
||||
print "Hello, this is t7, a tester for syncing of files in read only directory\n";
|
||||
|
||||
|
||||
# IMPORTANT NOTE :
|
||||
print "This test use the OWNCLOUD_TEST_PERMISSIONS environement variable and _PERM_xxx_ on filenames to set the permission. ";
|
||||
print "It does not rely on real permission set on the server. This test is just for testing the propagation choices\n";
|
||||
# "It would be nice" to have a test that test with real permissions on the server
|
||||
|
||||
$ENV{OWNCLOUD_TEST_PERMISSIONS} = "1";
|
||||
|
||||
initTesting();
|
||||
|
||||
printInfo( "Init" );
|
||||
|
||||
#create some files localy
|
||||
my $tmpdir = "/tmp/t7/";
|
||||
mkdir($tmpdir);
|
||||
createLocalFile( $tmpdir . "normalFile_PERM_WVND_.data", 100 );
|
||||
createLocalFile( $tmpdir . "cannotBeRemoved_PERM_WVN_.data", 101 );
|
||||
createLocalFile( $tmpdir . "canBeRemoved_PERM_D_.data", 102 );
|
||||
my $md5CanotBeModified = createLocalFile( $tmpdir . "canotBeModified_PERM_DVN_.data", 103 );
|
||||
createLocalFile( $tmpdir . "canBeModified_PERM_W_.data", 104 );
|
||||
|
||||
#put them in some directories
|
||||
createRemoteDir( "normalDirectory_PERM_CKDNV_" );
|
||||
glob_put( "$tmpdir/*", "normalDirectory_PERM_CKDNV_" );
|
||||
createRemoteDir( "readonlyDirectory_PERM_M_" );
|
||||
glob_put( "$tmpdir/*", "readonlyDirectory_PERM_M_" );
|
||||
createRemoteDir( "readonlyDirectory_PERM_M_/subdir_PERM_CK_" );
|
||||
createRemoteDir( "readonlyDirectory_PERM_M_/subdir_PERM_CK_/subsubdir_PERM_CKDNV_" );
|
||||
glob_put( "$tmpdir/normalFile_PERM_WVND_.data", "readonlyDirectory_PERM_M_/subdir_PERM_CK_/subsubdir_PERM_CKDNV_" );
|
||||
|
||||
|
||||
csync();
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
system("sleep 1"); #make sure changes have different mtime
|
||||
|
||||
printInfo( "Do some changes and see how they propagate" );
|
||||
|
||||
#1. remove the file than cannot be removed
|
||||
# (they should be recovered)
|
||||
unlink( localDir() . 'normalDirectory_PERM_CKDNV_/cannotBeRemoved_PERM_WVN_.data' );
|
||||
unlink( localDir() . 'readonlyDirectory_PERM_M_/cannotBeRemoved_PERM_WVN_.data' );
|
||||
|
||||
#2. remove the file that can be removed
|
||||
# (they should properly be gone)
|
||||
unlink( localDir() . 'normalDirectory_PERM_CKDNV_/canBeRemoved_PERM_D_.data' );
|
||||
unlink( localDir() . 'readonlyDirectory_PERM_M_/canBeRemoved_PERM_D_.data' );
|
||||
|
||||
#3. Edit the files that cannot be modified
|
||||
# (they should be recovered, and a conflict shall be created)
|
||||
system("echo 'modified' > ". localDir() . "normalDirectory_PERM_CKDNV_/canotBeModified_PERM_DVN_.data");
|
||||
system("echo 'modified_' > ". localDir() . "readonlyDirectory_PERM_M_/canotBeModified_PERM_DVN_.data");
|
||||
|
||||
#4. Edit other files
|
||||
# (they should be uploaded)
|
||||
system("echo '__modified' > ". localDir() . "normalDirectory_PERM_CKDNV_/canBeModified_PERM_W_.data");
|
||||
system("echo '__modified_' > ". localDir() . "readonlyDirectory_PERM_M_/canBeModified_PERM_W_.data");
|
||||
|
||||
#5. Create a new file in a read only folder
|
||||
# (they should not be uploaded)
|
||||
createLocalFile( localDir() . "readonlyDirectory_PERM_M_/newFile_PERM_WDNV_.data", 105 );
|
||||
|
||||
#6. Create a new file in a read only folder
|
||||
# (should be uploaded)
|
||||
createLocalFile( localDir() . "normalDirectory_PERM_CKDNV_/newFile_PERM_WDNV_.data", 106 );
|
||||
|
||||
#do the sync
|
||||
csync();
|
||||
|
||||
|
||||
#1.
|
||||
# File should be recovered
|
||||
assert( -e localDir(). 'normalDirectory_PERM_CKDNV_/cannotBeRemoved_PERM_WVN_.data' );
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/cannotBeRemoved_PERM_WVN_.data' );
|
||||
|
||||
#2.
|
||||
# File should be deleted
|
||||
assert( !-e localDir() . 'normalDirectory_PERM_CKDNV_/canBeRemoved_PERM_D_.data' );
|
||||
assert( !-e localDir() . 'readonlyDirectory_PERM_M_/canBeRemoved_PERM_D_.data' );
|
||||
|
||||
#3.
|
||||
# File should be recovered
|
||||
assert($md5CanotBeModified eq md5OfFile( localDir().'normalDirectory_PERM_CKDNV_/canotBeModified_PERM_DVN_.data' ));
|
||||
assert($md5CanotBeModified eq md5OfFile( localDir().'readonlyDirectory_PERM_M_/canotBeModified_PERM_DVN_.data' ));
|
||||
# and conflict created
|
||||
# TODO check that the conflict file has the right content
|
||||
assert( -e glob(localDir().'normalDirectory_PERM_CKDNV_/canotBeModified_PERM_DVN__conflict-*.data' ) );
|
||||
assert( -e glob(localDir().'readonlyDirectory_PERM_M_/canotBeModified_PERM_DVN__conflict-*.data' ) );
|
||||
# remove the conflicts for the next assertLocalAndRemoteDir
|
||||
system("rm " . localDir().'normalDirectory_PERM_CKDNV_/canotBeModified_PERM_DVN__conflict-*.data' );
|
||||
system("rm " . localDir().'readonlyDirectory_PERM_M_/canotBeModified_PERM_DVN__conflict-*.data' );
|
||||
|
||||
#4. File should be updated, that's tested by assertLocalAndRemoteDir
|
||||
|
||||
#5.
|
||||
# The file should not exist on the remote
|
||||
# TODO: test that the file is NOT on the server
|
||||
# but still be there
|
||||
assert( -e localDir() . "readonlyDirectory_PERM_M_/newFile_PERM_WDNV_.data" );
|
||||
# remove it so assertLocalAndRemoteDir succeed.
|
||||
unlink(localDir() . "readonlyDirectory_PERM_M_/newFile_PERM_WDNV_.data");
|
||||
|
||||
#6.
|
||||
# the file should be in the server and local
|
||||
assert( -e localDir() . "normalDirectory_PERM_CKDNV_/newFile_PERM_WDNV_.data" );
|
||||
|
||||
|
||||
### Both side should still be the same
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
||||
|
||||
|
||||
#######################################################################
|
||||
printInfo( "remove the read only directory" );
|
||||
# -> It must be recovered
|
||||
system("rm -r " . localDir().'readonlyDirectory_PERM_M_' );
|
||||
csync();
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/cannotBeRemoved_PERM_WVN_.data' );
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/subdir_PERM_CK_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
||||
#######################################################################
|
||||
printInfo( "move a directory in a outside read only folder" );
|
||||
#Missing directory should be restored
|
||||
#new directory should be uploaded
|
||||
system("mv " . localDir().'readonlyDirectory_PERM_M_/subdir_PERM_CK_ ' . localDir().'normalDirectory_PERM_CKDNV_/subdir_PERM_CKDNV_' );
|
||||
|
||||
# two syncs may be necessary for now
|
||||
csync();
|
||||
csync();
|
||||
|
||||
# old name restored
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/subdir_PERM_CK_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
|
||||
# new still exist
|
||||
assert( -e localDir(). 'normalDirectory_PERM_CKDNV_/subdir_PERM_CKDNV_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#######################################################################
|
||||
printInfo( "rename a directory in a read only folder and move a directory to a read-only" );
|
||||
|
||||
# do a sync to update the database
|
||||
csync();
|
||||
|
||||
#1. rename a directory in a read only folder
|
||||
#Missing directory should be restored
|
||||
#new directory should stay but not be uploaded
|
||||
system("mv " . localDir().'readonlyDirectory_PERM_M_/subdir_PERM_CK_ ' . localDir().'readonlyDirectory_PERM_M_/newname_PERM_CK_' );
|
||||
|
||||
#2. move a directory from read to read only (move the directory from previous step)
|
||||
system("mv " . localDir().'normalDirectory_PERM_CKDNV_/subdir_PERM_CKDNV_ ' . localDir().'readonlyDirectory_PERM_M_/moved_PERM_CK_' );
|
||||
|
||||
# two syncs may be necessary for now
|
||||
csync();
|
||||
csync();
|
||||
|
||||
#1.
|
||||
# old name restored
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/subdir_PERM_CK_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
|
||||
# new still exist
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/newname_PERM_CK_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
# but is not on server: so remove for assertLocalAndRemoteDir
|
||||
system("rm -r " . localDir(). "readonlyDirectory_PERM_M_/newname_PERM_CK_");
|
||||
|
||||
#2.
|
||||
# old removed
|
||||
assert( ! -e localDir(). 'normalDirectory_PERM_CKDNV_/subdir_PERM_CKDNV_/' );
|
||||
# new still there
|
||||
assert( -e localDir(). 'readonlyDirectory_PERM_M_/moved_PERM_CK_/subsubdir_PERM_CKDNV_/normalFile_PERM_WVND_.data' );
|
||||
#but not on server
|
||||
system("rm -r " . localDir(). "readonlyDirectory_PERM_M_/moved_PERM_CK_");
|
||||
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
||||
|
||||
cleanup();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
110
csync/tests/ownCloud/t8.pl
Executable file
|
@ -0,0 +1,110 @@
|
|||
#!/usr/bin/perl
|
||||
#
|
||||
# Test script for the ownCloud module of csync.
|
||||
# This script requires a running ownCloud instance accessible via HTTP.
|
||||
# It does quite some fancy tests and asserts the results.
|
||||
#
|
||||
# Copyright (C) by Olivier Goffart <ogoffart@woboq.com>
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License as published by the Free Software Foundation; either
|
||||
# version 2.1 of the License, or (at your option) any later version.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
use lib ".";
|
||||
|
||||
use Carp::Assert;
|
||||
use File::Copy;
|
||||
use ownCloud::Test;
|
||||
|
||||
use strict;
|
||||
|
||||
print "Hello, this is t8, a tester for syncing of files on a case sensitive FS\n";
|
||||
|
||||
|
||||
# The test is run on a 'normal' file system, but we tell pwncloud that it is case preserving anyway
|
||||
$ENV{OWNCLOUD_TEST_CASE_PRESERVING} = "1";
|
||||
|
||||
# FIXME! the code does not work with parallelism
|
||||
$ENV{OWNCLOUD_MAX_PARALLEL}="1";
|
||||
|
||||
initTesting();
|
||||
|
||||
printInfo( "Syncing two files with the same name that differ with case" );
|
||||
|
||||
#create some files localy
|
||||
my $tmpdir = "/tmp/t8/";
|
||||
mkdir($tmpdir);
|
||||
createLocalFile( $tmpdir . "HELLO.dat", 100 );
|
||||
createLocalFile( $tmpdir . "Hello.dat", 150 );
|
||||
createLocalFile( $tmpdir . "Normal.dat", 110 );
|
||||
|
||||
#put them in some directories
|
||||
createRemoteDir( "dir" );
|
||||
glob_put( "$tmpdir/*", "dir" );
|
||||
|
||||
csync();
|
||||
|
||||
# Check that only one of the two file was synced.
|
||||
# The one that exist here is undefined, the current implementation will take the
|
||||
# first one alphabetically, but the other one would also be fine. What's imporant
|
||||
# is that there is only one.
|
||||
assert( -e localDir() . 'dir/HELLO.dat' );
|
||||
assert( !-e localDir() . 'dir/Hello.dat' );
|
||||
|
||||
printInfo( "Remove one file should remove it on the server and download the other one" );
|
||||
unlink( localDir() . 'dir/HELLO.dat' );
|
||||
|
||||
csync();
|
||||
assert( -e localDir() . 'dir/Hello.dat' );
|
||||
assert( !-e localDir() . 'dir/HELLO.dat' );
|
||||
assertLocalAndRemoteDir( '', 0);
|
||||
|
||||
|
||||
printInfo( "Renaming one file to the same name as another one with different casing" );
|
||||
moveRemoteFile( 'dir/Hello.dat', 'dir/NORMAL.dat');
|
||||
|
||||
csync();
|
||||
|
||||
#It should not have do the move
|
||||
assert( -e localDir() . 'dir/Hello.dat' );
|
||||
assert( !-e localDir() . 'dir/NORMAL.dat' );
|
||||
assert( -e localDir() . 'dir/Normal.dat' );
|
||||
|
||||
printInfo( "Another directory with the same name but different casing is created" );
|
||||
|
||||
createRemoteDir( "DIR" );
|
||||
glob_put( "$tmpdir/*", "DIR" );
|
||||
|
||||
csync();
|
||||
|
||||
assert( !-e localDir() . 'DIR' );
|
||||
|
||||
|
||||
printInfo( "Remove the old dir localy" );
|
||||
|
||||
system("rm -r " . localDir() . "dir");
|
||||
|
||||
csync();
|
||||
|
||||
# now DIR was fetched
|
||||
assert( -e localDir() . 'DIR' );
|
||||
assert( -e localDir() . 'DIR/HELLO.dat' );
|
||||
assert( !-e localDir() . 'DIR/Hello.dat' );
|
||||
assert( !-e localDir() . 'dir' );
|
||||
|
||||
# dir/NORMAL.dat is still on the server
|
||||
|
||||
cleanup();
|
||||
system("rm -r " . $tmpdir);
|
||||
|
|
@ -1,45 +1,42 @@
|
|||
Setting up an Account
|
||||
=====================
|
||||
|
||||
If no account has been configured, the ownCloud Client will automatically
|
||||
assist in connecting to your ownCloud server after the application has been
|
||||
started.
|
||||
If no account has been configured, the ownCloud Client automatically assist in
|
||||
connecting to your ownCloud server after the application has been started.
|
||||
|
||||
As a first step, specify the URL to your Server. This is the same address
|
||||
that is used in the browser.
|
||||
To set up an account:
|
||||
|
||||
1. Specify the URL to your Server. This is the same address that is used in the browser.
|
||||
|
||||
.. image:: images/wizard_url.png
|
||||
:scale: 50 %
|
||||
|
||||
.. note:: Make sure to use ``https://`` if the server supports it. Otherwise,
|
||||
your password and all data will be transferred to the server unencrypted.
|
||||
This makes it easy for third parties to intercept your communication, and
|
||||
getting hold of your password!
|
||||
your password and all data will be transferred to the server unencrypted. This
|
||||
makes it easy for third parties to intercept your communication, and getting
|
||||
hold of your password!
|
||||
|
||||
Next, enter the username and password. These are the same credentials used
|
||||
to log into the web interface.
|
||||
2. Enter the username and password. These are the same credentials used to log into the web interface.
|
||||
|
||||
.. image:: images/wizard_user.png
|
||||
:scale: 50 %
|
||||
|
||||
Finally, choose the folder that ownCloud Client is supposed to sync the
|
||||
contents of your ownCloud account with. By default, this is a folder
|
||||
called `ownCloud`, which will be created in the home directory.
|
||||
3. Choose the folder with which you want the ownCloud Client to synchronize the
|
||||
contents of your ownCloud account. By default, this is a folder called
|
||||
`ownCloud`. This folder is created in the home directory.
|
||||
|
||||
.. image:: images/wizard_targetfolder.png
|
||||
:scale: 50 %
|
||||
|
||||
At this time, the synchronization between the root directories of the
|
||||
ownCloud server will begin.
|
||||
The synchronization between the root directories of the ownCloud server begins.
|
||||
|
||||
.. image:: images/wizard_overview.png
|
||||
:scale: 50 %
|
||||
|
||||
If selecting a local folder that already contains data, there are
|
||||
two options that exist.
|
||||
When selecting a local folder that already contains data, you can choose from two options:
|
||||
|
||||
* Keep local data: If selected, the files in the local folder on the
|
||||
client will be synced up to the ownCloud server.
|
||||
* Start a clean sync: If selected, all files in the local folder on
|
||||
the client will be deleted and therefore not synced to the ownCloud
|
||||
server.
|
||||
* :guilabel:`Keep local data`: When selected, the files in the local folder on
|
||||
the client are synchronized to the ownCloud server.
|
||||
|
||||
* :guilabel:`Start a clean sync`: When selected, all files in the local folder on the
|
||||
client are deleted. These files are not syncrhonized to the ownCloud server.
|
||||
|
|
|
@ -1,88 +1,96 @@
|
|||
Appendix B: Architecture
|
||||
========================
|
||||
Appendix B: History and Architecture
|
||||
====================================
|
||||
|
||||
.. index:: architecture
|
||||
.. index:: architecture
|
||||
|
||||
The ownCloud project provides desktop sync clients to synchronize the
|
||||
contents of local directories on the desktop machines to the ownCloud.
|
||||
ownCloud provides desktop sync clients to synchronize the contents of local
|
||||
directories from computers, tablets, and handheld devices to the ownCloud
|
||||
server.
|
||||
|
||||
The syncing is done with csync_, a bidirectional file synchronizing tool which
|
||||
provides both a command line client as well as a library. A special module for
|
||||
csync was written to synchronize with ownCloud’s built-in WebDAV server.
|
||||
Synchronization is accomplished using csync_, a bidirectional file
|
||||
synchronizing tool that provides both a command line client as well as a
|
||||
library. A special module for csync was written to synchronize with the
|
||||
ownCloud built-in WebDAV server.
|
||||
|
||||
The ownCloud sync client is based on a tool called mirall initially written by
|
||||
Duncan Mac Vicar. Later Klaas Freitag joined the project and enhanced it to work
|
||||
with ownCloud server.
|
||||
The ownCloud sync client is based on a tool called *mirall*, initially written
|
||||
by Duncan Mac Vicar. Later Klaas Freitag joined the project and enhanced it to
|
||||
function with the ownCloud server.
|
||||
|
||||
ownCloud Client is written in C++ using the `Qt Framework`_. As a result, the
|
||||
ownCloud Client runs on the three important platforms Linux, Windows and MacOS.
|
||||
The ownCloud Client software is written in C++ using the `Qt Framework`_. As a
|
||||
result, the ownCloud Client runs on Linux, Windows, and MacOS.
|
||||
|
||||
.. _csync: http://www.csync.org
|
||||
.. _`Qt Framework`: http://www.qt-project.org
|
||||
|
||||
The Sync Process
|
||||
----------------
|
||||
The Synchronization Process
|
||||
---------------------------
|
||||
|
||||
First it is important to recall what syncing is: It tries to keep the files
|
||||
on two repositories the same. That means if a file is added to one repository
|
||||
it is going to be copied to the other repository. If a file is changed on one
|
||||
repository, the change is propagated to the other repository. Also, if a file
|
||||
is deleted on one side, it is deleted on the other. As a matter of fact, in
|
||||
ownCloud syncing we do not have a typical client/server system where the
|
||||
server is always master.
|
||||
The process of synchronization keeps files in two separate repositories the same. When syncrhonized:
|
||||
|
||||
This is the major difference to other systems like a file backup where just
|
||||
changes and new files are propagated but files never get deleted.
|
||||
- If a file is added to one repository it is copied to the other synchronized repository.
|
||||
- When a file is changed in one repository, the change is propagated to any
|
||||
syncrhonized other repositories- If a file is deleted in one repository, it
|
||||
is deleted in any other.
|
||||
|
||||
The ownCloud Client checks both repositories for changes frequently after a
|
||||
certain time span. That is refered to as a sync run. In between the local
|
||||
repository is monitored by a file system monitor system that starts a sync run
|
||||
immediately if something was edited, added or removed.
|
||||
It is important to note that the ownCloud synchronization process does not use
|
||||
a typical client/server system where the server is always master. This is a
|
||||
major difference between the ownCloud syncrhonizatin process and other systems
|
||||
like a file backup, where only changes to files or folders and the addition of
|
||||
new files are propagated, but these files and folders are never deleted unless
|
||||
explicitly deleted in the backup.
|
||||
|
||||
Sync by Time versus ETag
|
||||
------------------------
|
||||
.. index:: time stamps, file times, etag, unique id
|
||||
During synchronization, the ownCloud Client checks both repositories for
|
||||
changes frequently. This process is referred to as a *sync run*. In between
|
||||
sync runs, the local repository is monitored by a file system monitoring
|
||||
process that starts a sync run immediately if something was edited, added, or
|
||||
removed.
|
||||
|
||||
Until the release of ownCloud 4.5 and ownCloud Client 1.1, ownCloud employed
|
||||
a single file property to decide which file is newer and hence needs to be
|
||||
synced to the other repository: the files modification time.
|
||||
Synchronization by Time versus ETag
|
||||
-----------------------------------
|
||||
.. index:: time stamps, file times, etag, unique id
|
||||
|
||||
Until the release of ownCloud 4.5 and ownCloud Client 1.1, the ownCloud
|
||||
synchronization process employed a single file property -- the file modificatin
|
||||
time -- to decide which file was newer and needed to be synchronized to the
|
||||
other repository.
|
||||
|
||||
The *modification timestamp* is part of the files metadata. It is available on
|
||||
every relevant filesystem and is the natural indicator for a file change.
|
||||
Modification timestamps do not require special action to create and have
|
||||
a general meaning. One design goal of csync is to not require a special server
|
||||
component, that’s why it was chosen as the backend component.
|
||||
every relevant filesystem and is the typical indicator for a file change.
|
||||
Modification timestamps do not require special action to create, and have a
|
||||
general meaning. One design goal of csync is to not require a special server
|
||||
component. This design goal is why csync was chosen as the backend component.
|
||||
|
||||
To compare the modification times of two files from different systems,
|
||||
it is needed to operate on the same base. Before version 1.1.0,
|
||||
csync requires both sides running on the exact same time, which can
|
||||
be achieved through enterprise standard `NTP time synchronisation`_ on all
|
||||
machines.
|
||||
To compare the modification times of two files from different systems, csync
|
||||
must operate on the same base. Before ownCloud Client version 1.1.0, csync
|
||||
required both device repositories to run on the exact same time. This
|
||||
requirement was achieved through the use of enterprise standard `NTP time
|
||||
synchronisation`_ on all machines.
|
||||
|
||||
Since this strategy is rather fragile without NTP, ownCloud 4.5 introduced a
|
||||
unique number, which changes whenever the file changes. Although it is a unique
|
||||
value, it is not a hash of the file, but a randomly chosen number, which it will
|
||||
transmit in the Etag_ field. Since the file number is guaranteed to change if
|
||||
the file changes, it can now be used to determine if one of the files has
|
||||
changed.
|
||||
Because this timing strategy is rather fragile without the use of NTP, ownCloud
|
||||
4.5 introduced a unique number (for each file?) that changes whenever the file
|
||||
changes. Although this number is a unique value, it is not a hash of the file.
|
||||
Instead, it is a randomly chosen number, that is transmitted in the Etag_
|
||||
field. Because the file number changes if the file changes, its use is
|
||||
guaranteed to determine if one of the files has changed and, thereby, launching
|
||||
a synchronization process.
|
||||
|
||||
.. note:: ownCloud Client 1.1 and newer require file ID capabilities on the
|
||||
ownCloud server, hence using them with a server earlier than 4.5.0 is
|
||||
not supported.
|
||||
.. note:: ownCloud Client release 1.1 and later requires file ID capabilities
|
||||
on the ownCloud server. Servers that run with release earlier than 4.5.0 do
|
||||
not support using the file ID functionality.
|
||||
|
||||
Before the 1.3.0 release of the client the sync process might create faux
|
||||
conflict files if time deviates. The original and the conflict files only
|
||||
differed in the timestamp, but not in content. This behaviour was changed
|
||||
towards a binary check if the files are different.
|
||||
Before the 1.3.0 release of the Desktop Client, the synchronization process
|
||||
might create faux conflict files if time deviates. Original and changed files
|
||||
conflict only in their timestamp, but not in their content. This behaviour was
|
||||
changed to employ a binary check if files differ.
|
||||
|
||||
Just like files, directories also hold a unique id, which changes whenever
|
||||
one of the contained files or directories gets modified. Since this is a
|
||||
recursive process, it significantly reduces the effort required for a sync
|
||||
cycle, because the client will only walk directories with a modified unique id.
|
||||
Like files, directories also hold a unique ID that changes whenever one of the
|
||||
contained files or directories is modified. Because this is a recursive
|
||||
process, it significantly reduces the effort required for a synchronization
|
||||
cycle, because the client only analyzes directories with a modified ID.
|
||||
|
||||
|
||||
This table outlines the different sync methods attempted depending
|
||||
on server/client combination:
|
||||
The following table outlines the different synchronization methods used,
|
||||
depending on server/client combination:
|
||||
|
||||
.. index:: compatiblity table
|
||||
|
||||
|
@ -98,10 +106,10 @@ on server/client combination:
|
|||
| 4.5 or later | 1.1 or later | File ID, Time Stamp |
|
||||
+--------------------+-------------------+----------------------------+
|
||||
|
||||
It is highly recommended to upgrade to ownCloud 4.5 or later with ownCloud
|
||||
Client 1.1 or later, since the time stamp-based sync mechanism can
|
||||
lead to data loss in certain edge-cases, especially when multiple clients
|
||||
are involved and one of them is not in sync with NTP time.
|
||||
We strongly recommend using ownCloud Server release 4.5 or later when using
|
||||
ownCloud Client 1.1 or later. Using incompatible time stamp-based
|
||||
synchronization mechanism can lead to data loss in rare cases, especially when
|
||||
multiple clients are involved and one utilizes a non-synchronized NTP time.
|
||||
|
||||
.. _`NTP time synchronisation`: http://en.wikipedia.org/wiki/Network_Time_Protocol
|
||||
.. _Etag: http://en.wikipedia.org/wiki/HTTP_ETag
|
||||
|
@ -109,27 +117,28 @@ are involved and one of them is not in sync with NTP time.
|
|||
Comparison and Conflict Cases
|
||||
-----------------------------
|
||||
|
||||
In a sync run the client first has to detect if one of the two repositories have
|
||||
changed files. On the local repository, the client traverses the file
|
||||
tree and compares the modification time of each file with the value it was
|
||||
before. The previous value is stored in the client's database. If it is not, it
|
||||
means that the file has been added to the local repository. Note that on
|
||||
the local side, the modificaton time a good attribute to detect changes because
|
||||
it does not depend on time shifts and such.
|
||||
As mentioned above, during a *sync run* the client must first detect if one of
|
||||
the two repositories have changed files. On the local repository, the client
|
||||
traverses the file tree and compares the modification time of each file with an
|
||||
expected value stored in its database. If the value is not the same, the client
|
||||
determines that the file has been modified in the local repository.
|
||||
|
||||
For the remote (ie. ownCloud) repository, the client compares the ETag of each
|
||||
file with it's previous value. Again the previous value is queried from the
|
||||
database. If the ETag is still the same, the file has not changed.
|
||||
.. note:: On the local side, the modificaton time a good attribute to use for detecting changes, because
|
||||
the value does not depend on time shifts and such.
|
||||
|
||||
In case a file has changed on both, the local and the remote repository since
|
||||
the last sync run, it can not easily be decided which version of the file is
|
||||
the one that should be used. However, changes to any side must not be lost.
|
||||
For the remote (that is, ownCloud server) repository, the client compares the
|
||||
ETag of each file with its expected value. Again, the expected ETag value is
|
||||
queried from the client database. If the ETag is the same, the file has not
|
||||
changed and no synchronization occurs.
|
||||
|
||||
That is called a **conflict case**. The client solves it by creating a conflict
|
||||
file of the older of the two files and save the newer one under the original
|
||||
file name. Conflict files are always created on the client and never on the
|
||||
server. The conflict file has the same name as the original file appended with
|
||||
the timestamp of the conflict detection.
|
||||
In the event a file has changed on both the local and the remote repository
|
||||
since the last sync run, it can not easily be decided which version of the file
|
||||
is the one that should be used. However, changes to any side be lost. Instead,
|
||||
a *conflict case* is created. The client resolves this conflic by creating a
|
||||
conflict file of the older of the two files and saving the newer file under the
|
||||
original file name. Conflict files are always created on the client and never
|
||||
on the server. The conflict file uses the same name as the original file, but
|
||||
is appended with the timestamp of the conflict detection.
|
||||
|
||||
|
||||
.. _ignored-files-label:
|
||||
|
@ -137,40 +146,40 @@ the timestamp of the conflict detection.
|
|||
Ignored Files
|
||||
-------------
|
||||
|
||||
ownCloud Client supports that certain files are excluded or ignored from
|
||||
the synchronization. There are a couple of system wide file patterns which
|
||||
come with the client. Custom patterns can be added by the user.
|
||||
The ownCloud Client supports the ability to exclude or ignore certain files
|
||||
from the synchronization process. Some system wide file patterns that are used
|
||||
to exclude or ignore files are included with the client by default and the
|
||||
ownCloud Client provides the ability to add custom patterns.
|
||||
|
||||
ownCloud Client will ignore the following files:
|
||||
By default, the ownCloud Client ignores the following files:
|
||||
|
||||
* Files matched by one of the pattern in :ref:`ignoredFilesEditor-label`
|
||||
* Files containing characters that do not work on certain file systems.
|
||||
Currently, these characters are: `\, :, ?, *, ", >, <, |`
|
||||
* Files starting in ``.csync_journal.db*`` (reserved for journalling)
|
||||
- Files matched by one of the patterns defined in :ref:`ignoredFilesEditor-label`.
|
||||
- Files containing characters that do not work on certain file systems (`\, :, ?, *, ", >, <, |`).
|
||||
* Files starting in ``.csync_journal.db*``, as these files are reserved for journalling.
|
||||
|
||||
If a pattern is checkmarked in the `ignoredFilesEditor-label` (or if a line in
|
||||
the exclude file starts with the character `]` directly followed
|
||||
by the file pattern), files matching this pattern are considered fleeting
|
||||
meta data. These files are ingored and *removed* by the client if found
|
||||
in the sync folder. This is suitable for meta files created by some
|
||||
If a pattern selected using a checkbox in the `ignoredFilesEditor-label` (or if
|
||||
a line in the exclude file starts with the character `]` directly followed by
|
||||
the file pattern), files matching the pattern are considered *fleeting meta
|
||||
data*. These files are ingored and *removed* by the client if found in the
|
||||
synchronized folder. This is suitable for meta files created by some
|
||||
applications that have no sustainable meaning.
|
||||
|
||||
If a pattern is ending with character `/` it means that only directories are
|
||||
matched. The pattern is only applied for directory components of the checked
|
||||
filename.
|
||||
If a pattern ends with the backslash (`/`) character, only directories are
|
||||
matched. The pattern is only applied for directory components of filenames
|
||||
selected using the checkbox.
|
||||
|
||||
To match file names against the exclude patterns, the unix standard C
|
||||
library function fnmatch is used. It checks the filename against the pattern
|
||||
using standard shell wildcard pattern matching. Check `The opengroup website
|
||||
<http://pubs.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html#tag_02_13_01>`
|
||||
for the gory details.
|
||||
To match filenames against the exclude patterns, the unix standard C library
|
||||
function fnmatch is used. This procesx checks the filename against the
|
||||
specified pattern using standard shell wildcard pattern matching. For more
|
||||
information, please refer to `The opengroup website
|
||||
<http://pubs.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html#tag_02_13_01>`.
|
||||
|
||||
The path that is checked is the relative path unter the sync root directory.
|
||||
The path that is checked is the relative path under the sync root directory.
|
||||
|
||||
**Pattern and File Match Examples:**
|
||||
|
||||
Examples:
|
||||
^^^^^^^^^
|
||||
+-----------+------------------------------+
|
||||
| Pattern | Matches |
|
||||
| Pattern | File Matches |
|
||||
+===========+==============================+
|
||||
| ``~$*`` | ``~$foo``, ``~$example.doc`` |
|
||||
+-----------+------------------------------+
|
||||
|
@ -183,15 +192,17 @@ Examples:
|
|||
The Sync Journal
|
||||
----------------
|
||||
|
||||
The client stores the ETag number in a per-directory database,
|
||||
called the journal. It is a hidden file right in the directory
|
||||
to be synced.
|
||||
The client stores the ETag number in a per-directory database, called the
|
||||
*journal*. This database is a hidden file contained in the directory to be
|
||||
synchronized.
|
||||
|
||||
If the journal database gets removed, ownCloud Client's CSync backend will
|
||||
rebuild the database by comparing the files and their modification times. Thus
|
||||
it should be made sure that both server and client synchronized with NTP time
|
||||
before restarting the client after a database removal.
|
||||
If the journal database is removed, the ownCloud Client CSync backend rebuilds
|
||||
the database by comparing the files and their modification times. This process
|
||||
ensures that both server and client are synchronized using the appropriate NTP
|
||||
time before restarting the client following a database removal.
|
||||
|
||||
Pressing ``F5`` in the Account Settings Dialog that allows to "reset" the
|
||||
journal. That can be used to recreate the journal database. Use this only
|
||||
if advised to do so by the developer or support staff.
|
||||
Pressing ``F5`` while in the Account Settings Dialog enables you to "reset" the
|
||||
journal. This function can be used to recreate the journal database.
|
||||
|
||||
.. note:: We recommend that you use this function only when advised to do so by
|
||||
ownCloud support staff.
|
||||
|
|
|
@ -1,81 +1,126 @@
|
|||
The Automatic Updater
|
||||
=====================
|
||||
|
||||
To ensure you're always using the latest version of ownCloud Client, an
|
||||
auto-update mechanism has been added in Version 1.5.1. It will ensure
|
||||
that will automatically profit from the latest features and bugfixes.
|
||||
To ensure that you are always using the latest version of the ownCloud client,
|
||||
an auto-update mechanism has been added in Version 1.5.1. The Automatic Updater
|
||||
ensures that you automatically profit from the latest features and bugfixes.
|
||||
|
||||
The updater works differently depending on the operating system.
|
||||
.. note:: The Automatic Updater functions differently, depending on the operating system.
|
||||
|
||||
Basic Workflow
|
||||
--------------
|
||||
|
||||
The following sections describe how to use the Automatic Updater on different operating systems:
|
||||
|
||||
Windows
|
||||
^^^^^^^
|
||||
|
||||
ownCloud client will check for updates and download the update if one
|
||||
is available. You can view the status under ``Settings -> General -> Updates``.
|
||||
If an update is available and has been successfully downloaded, ownCloud
|
||||
Client will start a silent update prior to its next launch and then start itself.
|
||||
If the silent update fails, the client offers a manual download.
|
||||
The ownCloud client checks for updates and downloads them when available. You
|
||||
can view the update status under ``Settings -> General -> Updates`` in the
|
||||
ownCloud client.
|
||||
|
||||
.. note:: The user needs to be able to attain administrative privileges
|
||||
to successfully perform the update.
|
||||
If an update is available, and has been successfully downloaded, the ownCloud
|
||||
client starts a silent update prior to its next launch and then restarts
|
||||
itself. Should the silent update fail, the client offers a manual download.
|
||||
|
||||
.. note:: Administrative privileges are required to perform the update.
|
||||
|
||||
Mac OS X
|
||||
^^^^^^^^
|
||||
|
||||
If a new update is available, ownCloud client will ask the user to update
|
||||
to the latest version using a pop-up dialog. This is the default for Mac
|
||||
OS X applications which use the Sparkle framework.
|
||||
If a new update is available, the ownCloud client initializes a pop-up dialog
|
||||
to alert you of the update and requesting that you update to the latest
|
||||
version. Due to their use of the Sparkle frameworks, this is the default
|
||||
process for Mac OS X applications.
|
||||
|
||||
Linux
|
||||
^^^^^
|
||||
|
||||
Since distributions provide their own update tool, ownCloud Client on Linux
|
||||
will not perform any updates on its own. It will, however, check for the
|
||||
latest version and passively notify the user (``Settings -> General -> Updates``)
|
||||
if an update is available.
|
||||
Linux distributions provide their own update tool, so ownCloud clients that use
|
||||
the Linux operating system do not perform any updates on their own. Linux
|
||||
operating systems do, however, check for the latest version of the ownCloud
|
||||
client and passively notify the user (``Settings -> General -> Updates``) when
|
||||
an update is available.
|
||||
|
||||
|
||||
Preventing Auto Updates
|
||||
-----------------------
|
||||
Preventing Automatic Updates
|
||||
----------------------------
|
||||
|
||||
In controlled environment such as companies or universities, the auto-update
|
||||
mechanism might not be desired as it interferes with controlled deployment
|
||||
tools and policies. In this case, it is possible to disable the auto-updater
|
||||
entirely:
|
||||
In controlled environments, such as companies or universities, you might not
|
||||
want to enable the auto-update mechanism, as it interferes with controlled
|
||||
deployment tools and policies. To address this case, it is possible to disable
|
||||
the auto-updater entirely. The following sections describe how to disable the
|
||||
auto-update mechanism for different operating systems.
|
||||
|
||||
Windows
|
||||
^^^^^^^
|
||||
Preventing Automatic Updates in Windows Environents
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
There are two alternative approaches:
|
||||
You can prevent automatic updates from occuring in Windows environments using
|
||||
one of two methods. The first method allows users to override the automatic
|
||||
update check mechanism whereas the second method prevents any manual overrides.
|
||||
|
||||
1. In ``HKEY_LOCAL_MACHINE\Software\ownCloud\ownCloud``, add a key ``skipUpdateCheck`` (of type DWORD) with the value 1 to the machine. This key
|
||||
can be manually overrideen by the same value in ``HKEY_CURRENT_USER``.
|
||||
To prevent automatic updates, but allow manual overrides:
|
||||
|
||||
2. In ``HKEY_LOCAL_MACHINE\Software\Policies\ownCloud\ownCloud``, add a key
|
||||
``skipUpdateCheck`` (of type DWORD) with the value 1 to the machine.
|
||||
Setting the value here cannot be overridden by the user and is the preferred
|
||||
way to control the updater behavior via Group Policies.
|
||||
1. Migrate to the following directory::
|
||||
|
||||
Mac OS X
|
||||
^^^^^^^^
|
||||
HKEY_LOCAL_MACHINE\Software\ownCloud\ownCloud
|
||||
|
||||
You can disable the update check via a system-wide ``.plist`` file located
|
||||
at ``/Library/Preferences/com.owncloud.desktopclient.plist``. Add a new root
|
||||
level item of type bool and the name ``skipUpdateCheck`` and set it to ``true``.
|
||||
You can also just copy the file
|
||||
``owncloud.app/Contents/Resources/deny_autoupdate_com.owncloud.desktopclient.plist```
|
||||
2. Add the key ``skipUpdateCheck`` (of type DWORD).
|
||||
|
||||
3. Specify a value of ``1`` to the machine.
|
||||
|
||||
To manually override this key, use the same value in ``HKEY_CURRENT_USER``.
|
||||
|
||||
To prevent automatic updates and disallow manual overrides:
|
||||
|
||||
.. note::This is the preferred method of controlling the updater behavior using Group Policies.
|
||||
|
||||
1. Migrate to the following directory::
|
||||
|
||||
HKEY_LOCAL_MACHINE\Software\Policies\ownCloud\ownCloud
|
||||
|
||||
2. Add the key ``skipUpdateCheck`` (of type DWORD).
|
||||
|
||||
3. Specify a value of ``1`` to the machine.
|
||||
|
||||
|
||||
Preventing Automatic Updates in Mac OS X Environments
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
You can disable the automatic update mechanism in MAC OS X operating systems
|
||||
using the system-wide ``.plist`` file. To access this file:
|
||||
|
||||
1. Using the Windows explorer, migrate to the following location::
|
||||
|
||||
/Library/Preferences/
|
||||
|
||||
2. Locate and open the following file::
|
||||
|
||||
com.owncloud.desktopclient.plist
|
||||
|
||||
3. Add a new root level item of type ``bool``.
|
||||
|
||||
4. Name the item ``skipUpdateCheck``.
|
||||
|
||||
5. Set the item to ``true``.
|
||||
|
||||
Alternatively, you can copy the file
|
||||
``owncloud.app/Contents/Resources/deny_autoupdate_com.owncloud.desktopclient.plist``
|
||||
to ``/Library/Preferences/com.owncloud.desktopclient.plist``.
|
||||
|
||||
Linux
|
||||
^^^^^
|
||||
Preventing Automatic Updates in Linux Environments
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Since there is no updating functionality, there is no need to remove the check.
|
||||
If you want to disable the check nontheless, open a file called
|
||||
``/etc/ownCloud/ownCloud.conf`` and add the following content::
|
||||
Because Linux does not provide automatic updating functionality, there is no
|
||||
need to remove the automatic-update check. However, if you want to disable
|
||||
this check:
|
||||
|
||||
[General]
|
||||
skipUpdateCheck=true
|
||||
1. Locate and open the following file::
|
||||
|
||||
/etc/ownCloud/ownCloud.conf
|
||||
|
||||
2. Add the following content to the file::
|
||||
|
||||
[General]
|
||||
skipUpdateCheck=true
|
||||
|
||||
|
|
160
doc/building.rst
|
@ -3,20 +3,20 @@
|
|||
Appendix A: Building the Client
|
||||
===============================
|
||||
|
||||
This section explains how to build the ownCloud Client from source
|
||||
for all major platforms. You should read this section if you want
|
||||
to development on the desktop client.
|
||||
This section explains how to build the ownCloud Client from source for all
|
||||
major platforms. You should read this section if you want to develop for the
|
||||
desktop client.
|
||||
|
||||
Note that the building instruction are subject to change as development
|
||||
proceeds. It is important to check the version which is to built.
|
||||
.. note:: Building instruction are subject to change as development proceeds.
|
||||
Please check the version for which you want to built.
|
||||
|
||||
This instructions were updated to work with ownCloud Client 1.5.
|
||||
The instructions contained in this topic were updated to work with version 1.5 of the ownCloud Client.
|
||||
|
||||
Linux
|
||||
-----
|
||||
|
||||
1. Add the `ownCloud repository from OBS`_.
|
||||
2. Install the dependencies (as root, or via sudo):
|
||||
2. Install the dependencies (as root, or using ``sudo``) using the following commands for your specific Linux distribution:
|
||||
|
||||
* Debian/Ubuntu: ``apt-get update; apt-get build-dep owncloud-client``
|
||||
* openSUSE: ``zypper ref; zypper si -d owncloud-client``
|
||||
|
@ -27,47 +27,51 @@ Linux
|
|||
Mac OS X
|
||||
--------
|
||||
|
||||
Next to XCode (and the command line tools!), you will need some
|
||||
extra dependencies.
|
||||
In additon to needing XCode (along with the command line tools), developing in
|
||||
the MAC OS X environment requires extra dependencies. You can install these
|
||||
dependencies through MacPorts_ or Homebrew_. These dependencies are required
|
||||
only on the build machine, because non-standard libs are deployed in the app
|
||||
bundle.
|
||||
|
||||
You can install these dependencies via MacPorts_ or Homebrew_.
|
||||
This is only needed on the build machine, since non-standard libs
|
||||
will be deployed in the app bundle.
|
||||
The tested and preferred way to develop in this environment is through the use
|
||||
of HomeBrew_. The ownCloud team has its own repository containing non-standard
|
||||
recipes.
|
||||
|
||||
The tested and preferred way is to use HomeBrew_. The ownCloud team has
|
||||
its own repository which contains non-standard recipes. Add it with::
|
||||
To set up your build enviroment for development using HomeBrew_:
|
||||
|
||||
1. Add the ownCloud repository using the following command::
|
||||
|
||||
brew tap owncloud/owncloud
|
||||
|
||||
Next, install the missing dependencies::
|
||||
2. Install any missing dependencies::
|
||||
|
||||
brew install $(brew deps mirall)
|
||||
|
||||
|
||||
To build mirall, follow the `generic build instructions`_.
|
||||
|
||||
.. note::
|
||||
You should not call ``make install`` at any time, since the product of the
|
||||
mirall build is an app bundle. Call ``make package`` instead to create an
|
||||
install-ready disk image.
|
||||
.. note:: Because the product from the mirall build is an app bundle, do not
|
||||
call ``make install`` at any time. Instead, call ``make package`` to create an
|
||||
install-ready disk image.
|
||||
|
||||
Windows (cross-compile)
|
||||
Windows (Cross-Compile)
|
||||
-----------------------
|
||||
|
||||
Due to the amount of dependencies, building the client for Windows
|
||||
is **currently only supported on openSUSE**, by using the MinGW
|
||||
cross compiler. You can set up openSUSE 12.1, 12.2 or 13.1 in a virtual machine
|
||||
if you do not have it installed already.
|
||||
Due to the large number of dependencies, building the client for Windows is
|
||||
**currently only supported on openSUSE**, by using the MinGW cross compiler.
|
||||
You can set up openSUSE 12.1, 12.2, or 13.1 in a virtual machine if you do not
|
||||
have it installed already.
|
||||
|
||||
In order to cross-compile, the following repositories need to be added
|
||||
via YaST or ``zypper ar`` (adjust when using openSUSE 12.2 or 13.1)::
|
||||
To cross-compile:
|
||||
|
||||
zypper ar http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_13.1/windows:mingw:win32.repo
|
||||
zypper ar http://download.opensuse.org/repositories/windows:/mingw/openSUSE_13.1/windows:mingw.repo
|
||||
1. Add the following repositories using YaST or ``zypper ar`` (adjust when using openSUSE 12.2 or 13.1):
|
||||
|
||||
Next, install the cross-compiler packages and the cross-compiled dependencies::
|
||||
- ``zypper ar http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_13.1/windows:mingw:win32.repo``
|
||||
|
||||
zypper install cmake make mingw32-cross-binutils mingw32-cross-cpp mingw32-cross-gcc \
|
||||
- ``zypper ar http://download.opensuse.org/repositories/windows:/mingw/openSUSE_13.1/windows:mingw.repo``
|
||||
|
||||
2. Install the cross-compiler packages and the cross-compiled dependencies::
|
||||
|
||||
``zypper install cmake make mingw32-cross-binutils mingw32-cross-cpp mingw32-cross-gcc \
|
||||
mingw32-cross-gcc-c++ mingw32-cross-pkg-config mingw32-filesystem \
|
||||
mingw32-headers mingw32-runtime site-config mingw32-libqt4-sql \
|
||||
mingw32-libqt4-sql-sqlite mingw32-sqlite mingw32-libsqlite-devel \
|
||||
|
@ -78,74 +82,86 @@ Next, install the cross-compiler packages and the cross-compiled dependencies::
|
|||
mingw32-libpng-devel mingw32-libsqlite mingw32-qtkeychain \
|
||||
mingw32-qtkeychain-devel mingw32-dlfcn mingw32-libintl-devel \
|
||||
mingw32-libneon-devel mingw32-libopenssl-devel mingw32-libproxy-devel \
|
||||
mingw32-libxml2-devel mingw32-zlib-devel
|
||||
mingw32-libxml2-devel mingw32-zlib-devel``
|
||||
|
||||
For the installer, the NSIS installer package is also required::
|
||||
3. For the installer, install the NSIS installer package::
|
||||
|
||||
zypper install mingw32-cross-nsis
|
||||
``zypper install mingw32-cross-nsis``
|
||||
|
||||
.. Usually, the following would be needed as well, but due to a bug in mingw, they
|
||||
will currently not build properly from source.
|
||||
4. Install the following plugin::
|
||||
|
||||
mingw32-cross-nsis-plugin-processes mingw32-cross-nsis-plugin-uac
|
||||
``mingw32-cross-nsis-plugin-processes mingw32-cross-nsis-plugin-uac``
|
||||
|
||||
You will also need to manually download and install the following files with
|
||||
``rpm -ivh <package>`` (They will also work with openSUSE 12.2 and newer)::
|
||||
.. note:: This plugin is typically required. However, due to a current bug
|
||||
in ``mingw``, the plugins do not currently build properly from source.
|
||||
|
||||
rpm -ihv http://download.tomahawk-player.org/packman/mingw:32/openSUSE_12.1/x86_64/mingw32-cross-nsis-plugin-processes-0-1.1.x86_64.rpm
|
||||
rpm -ihv http://download.tomahawk-player.org/packman/mingw:32/openSUSE_12.1/x86_64/mingw32-cross-nsis-plugin-uac-0-3.1.x86_64.rpm
|
||||
5. Manually download and install the following files using ``rpm -ivh <package>``:
|
||||
|
||||
Now, follow the `generic build instructions`_, but pay attention to
|
||||
the following differences:
|
||||
..note:: These files operate using openSUSE 12.2 and newer.
|
||||
|
||||
For building for windows a special toolchain file has to be specified.
|
||||
That makes cmake finding the platform specific tools. This parameter
|
||||
has to be added to the call to cmake:
|
||||
- ``rpm -ihv http://download.tomahawk-player.org/packman/mingw:32/openSUSE_12.1/x86_64/mingw32-cross-nsis-plugin-processes-0-1.1.x86_64.rpm``
|
||||
|
||||
``-DCMAKE_TOOLCHAIN_FILE=../mirall/admin/win/Toolchain-mingw32-openSUSE.cmake``
|
||||
- ``rpm -ihv http://download.tomahawk-player.org/packman/mingw:32/openSUSE_12.1/x86_64/mingw32-cross-nsis-plugin-uac-0-3.1.x86_64.rpm``
|
||||
|
||||
Finally, just build by running ``make``. ``make package`` will produce
|
||||
an NSIS-based installer, provided the NSIS mingw32 packages are installed.
|
||||
6. Follow the `generic build instructions`_
|
||||
|
||||
.. note:: When building for Windows platforms, you must specify a special
|
||||
toolchain file that enables cmake to locate the platform-specific tools. To add
|
||||
this parameter to the call to cmake, enter
|
||||
``DCMAKE_TOOLCHAIN_FILE=../mirall/admin/win/Toolchain-mingw32-openSUSE.cmake``.
|
||||
|
||||
7. Build by running ``make``.
|
||||
|
||||
..note:: Using ``make package`` produces an NSIS-based installer, provided
|
||||
the NSIS mingw32 packages are installed.
|
||||
|
||||
Generic Build Instructions
|
||||
--------------------------
|
||||
.. _`generic build instructions`
|
||||
|
||||
Compared to previous versions building of Mirall has become more easy.
|
||||
CSync, which is the sync engine library of Mirall, is now part of the
|
||||
Mirall source repository, not, like it was before, a separate module.
|
||||
Compared to previous versions, building Mirall has become easier. Unlike
|
||||
earlier versions, CSync, which is the sync engine library of Mirall, is now
|
||||
part of the Mirall source repository and not a separate module.
|
||||
|
||||
Mirall can be downloaded at ownCloud's `Client Download Page`_.
|
||||
You can download Mirall from the ownCloud `Client Download Page`_.
|
||||
|
||||
If you want to build the leading edge version of the client, you should
|
||||
use the latest versions of Mirall via Git_, like so::
|
||||
To build the most up to date version of the client:
|
||||
|
||||
git clone git://github.com/owncloud/mirall.git
|
||||
1. Clone the latest versions of Mirall from Git_ as follows:
|
||||
|
||||
Next, create build directories::
|
||||
``git clone git://github.com/owncloud/mirall.git``
|
||||
|
||||
mkdir mirall-build
|
||||
2. Create build directories:
|
||||
|
||||
Now build mirall::
|
||||
``mkdir mirall-build``
|
||||
|
||||
cd ../mirall-build
|
||||
cmake -DCMAKE_BUILD_TYPE="Debug" ../mirall
|
||||
3. Build mirall:
|
||||
|
||||
Note that it is important to use absolute pathes for the include- and library
|
||||
directories. If this succeeds, call ``make``. The owncloud binary should appear
|
||||
in the ``bin`` directory. You can also run ``make install`` to install the client to
|
||||
``/usr/local/bin``.
|
||||
``cd ../mirall-build``
|
||||
``cmake -DCMAKE_BUILD_TYPE="Debug" ../mirall``
|
||||
|
||||
To build an installer/app bundle (requires the mingw32-cross-nsis packages on Windows)::
|
||||
..note:: You must use absolute pathes for the ``include`` and ``library`` directories.
|
||||
|
||||
make package
|
||||
4. Call ``make``.
|
||||
|
||||
Known cmake parameters:
|
||||
The owncloud binary appear in the ``bin`` directory.
|
||||
|
||||
* QTKEYCHAIN_LIBRARY=/path/to/qtkeychain.dylib -DQTKEYCHAIN_INCLUDE_DIR=/path/to/qtkeychain/: Use QtKeychain for stored credentials. When compiling with Qt5, the library is called qt5keychain.dylib. You need to compile QtKeychain with the same Qt version.
|
||||
* WITH_DOC=TRUE: create doc and manpages via running ``make``; also adds install statements to be able to install it via ``make install``.
|
||||
* CMAKE_PREFIX_PATH=/path/to/Qt5.2.0/5.2.0/yourarch/lib/cmake/ : to build with Qt5
|
||||
* BUILD_WITH_QT4=ON : to build with Qt4 even if Qt5 is found
|
||||
5. (Optional) Call ``make install`` to install the client to the ``/usr/local/bin`` directory.
|
||||
|
||||
6. (Optional) Call ``make package`` to build an installer/app bundle
|
||||
|
||||
..note:: This step requires the ``mingw32-cross-nsis`` packages be installed on Windows.
|
||||
|
||||
The following are known cmake parameters:
|
||||
|
||||
* ``QTKEYCHAIN_LIBRARY=/path/to/qtkeychain.dylib -DQTKEYCHAIN_INCLUDE_DIR=/path/to/qtkeychain/``:
|
||||
Used for stored credentials. When compiling with Qt5, the library is called ``qt5keychain.dylib.``
|
||||
You need to compile QtKeychain with the same Qt version.
|
||||
* ``WITH_DOC=TRUE``: Creates doc and manpages through running ``make``; also
|
||||
* adds install statements, providing the ability to install using ``make
|
||||
* install``.
|
||||
* ``CMAKE_PREFIX_PATH=/path/to/Qt5.2.0/5.2.0/yourarch/lib/cmake/``: Builds using Qt5.
|
||||
* ``BUILD_WITH_QT4=ON``: Builds using Qt4 (even if Qt5 is found).
|
||||
|
||||
.. _`ownCloud repository from OBS`: http://software.opensuse.org/download/package?project=isv:ownCloud:devel&package=owncloud-client
|
||||
.. _CSync: http://www.csync.org
|
||||
|
|
|
@ -1,26 +1,24 @@
|
|||
ownCloud Client reads a configuration file.
|
||||
The ownCloud Client reads a configuration file. You can locate this configuration files as follows:
|
||||
|
||||
On Linux it can be found in:
|
||||
- On Linux distributions:
|
||||
``$HOME/.local/share/data/ownCloud/owncloud.cfg``
|
||||
|
||||
On Windows it can be found in:
|
||||
- In Microsoft Windows systems:
|
||||
``%LOCALAPPDATA%\ownCloud\owncloud.cfg``
|
||||
|
||||
On Mac it can be found in:
|
||||
- In MAC OS X systems:
|
||||
``$HOME/Library/Application Support/ownCloud``
|
||||
|
||||
|
||||
It contains settings in the ini file format known from Windows.
|
||||
The configuration file contains settings using the Microsoft Windows .ini file
|
||||
format. You can overwrite changes using the ownCloud configuration dialog.
|
||||
|
||||
.. note:: Changes here should be done carefully as wrong settings can cause disfunctionality.
|
||||
.. note:: Use caution when making changes to the ownCloud Client configuration
|
||||
file. Incorrect settings can produce unintended results.
|
||||
|
||||
.. note:: Changes may be overwritten by using ownCloud's configuration dialog.
|
||||
You can change the following configuration settings:
|
||||
|
||||
These are config settings that may be changed:
|
||||
- ``remotePollInterval`` (default: ``30000``) -- Specifies the poll time for the remote repository in milliseconds.
|
||||
|
||||
``remotePollInterval`` (default: ``30000``)
|
||||
Poll time for the remote repository in milliseconds
|
||||
|
||||
``maxLogLines`` (default: ``20000``)
|
||||
Maximum count of log lines shown in the log window
|
||||
- ``maxLogLines`` (default: ``20000``) -- Specifies the maximum number of log lines displayed in the log window.
|
||||
|
||||
|
|
19
doc/faq.rst
|
@ -1,16 +1,17 @@
|
|||
FAQ
|
||||
===
|
||||
|
||||
Some files are continuously uploaded to the server even when they are not modified
|
||||
----------------------------------------------------------------------------------
|
||||
**Issue:**
|
||||
|
||||
Some files are continuously uploaded to the server, even when they are not modified.
|
||||
|
||||
**Resolution:**
|
||||
|
||||
It is possible that another program is changing the modification date of the file.
|
||||
|
||||
If the file is a ``.eml`` file, Windows automatically change all file all the time unless you remove
|
||||
``\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\PropertySystem\PropertyHandlers`` from
|
||||
the windows registry.
|
||||
See http://petersteier.wordpress.com/2011/10/22/windows-indexer-changes-modification-dates-of-eml-files/
|
||||
|
||||
|
||||
|
||||
If the file is uses the ``.eml`` extention, Windows automatically and
|
||||
continually changes all files, unless you remove
|
||||
``\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\PropertySystem\PropertyHandlers`
|
||||
from the windows registry.
|
||||
|
||||
See http://petersteier.wordpress.com/2011/10/22/windows-indexer-changes-modification-dates-of-eml-files/ for more information.
|
||||
|
|
BIN
doc/images/client_setup_wizard_components.png
Normal file
After Width: | Height: | Size: 34 KiB |
BIN
doc/images/client_setup_wizard_install_finish.png
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
doc/images/client_setup_wizard_install_progress.png
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
doc/images/client_setup_wizard_location.png
Normal file
After Width: | Height: | Size: 30 KiB |
BIN
doc/images/client_setup_wizard_main.png
Normal file
After Width: | Height: | Size: 25 KiB |
BIN
doc/images/client_setup_wizard_reinstall.png
Normal file
After Width: | Height: | Size: 33 KiB |
BIN
doc/images/client_setup_wizard_uninstall.png
Normal file
After Width: | Height: | Size: 33 KiB |
BIN
doc/images/client_setup_wizard_uninstall_2.png
Normal file
After Width: | Height: | Size: 28 KiB |
BIN
doc/images/client_setup_wizard_uninstall_3.png
Normal file
After Width: | Height: | Size: 30 KiB |
BIN
doc/images/download_button.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
doc/images/log_output_window.png
Normal file
After Width: | Height: | Size: 43 KiB |
BIN
doc/images/oc_client_download_options.png
Normal file
After Width: | Height: | Size: 7 KiB |
BIN
doc/images/oc_client_linux_download.png
Normal file
After Width: | Height: | Size: 34 KiB |
BIN
doc/images/oc_client_macosx_download.png
Normal file
After Width: | Height: | Size: 33 KiB |
BIN
doc/images/oc_client_windows_download.png
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
doc/images/oc_client_windows_option.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
doc/images/oc_connection_wizard_credentials.png
Normal file
After Width: | Height: | Size: 32 KiB |
BIN
doc/images/oc_connection_wizard_finish.png
Normal file
After Width: | Height: | Size: 40 KiB |
BIN
doc/images/oc_connection_wizard_localfolder.png
Normal file
After Width: | Height: | Size: 36 KiB |
BIN
doc/images/oc_connection_wizard_server.png
Normal file
After Width: | Height: | Size: 32 KiB |
BIN
doc/images/oc_website.png
Normal file
After Width: | Height: | Size: 71 KiB |
BIN
doc/images/owncloud_logo_transparent.png
Normal file
After Width: | Height: | Size: 46 KiB |
BIN
doc/images/owncloud_small_wh_bl.jpg
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
doc/images/save_log_file.png
Normal file
After Width: | Height: | Size: 66 KiB |
BIN
doc/images/security_warning_windows.png
Normal file
After Width: | Height: | Size: 13 KiB |
|
@ -4,11 +4,12 @@ Contents
|
|||
========
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
:maxdepth: 3
|
||||
|
||||
introduction
|
||||
installing
|
||||
accountsetup
|
||||
visualtour
|
||||
navigating
|
||||
advancedusage
|
||||
autoupdate
|
||||
|
||||
|
|
208
doc/installing-linux.rst
Normal file
|
@ -0,0 +1,208 @@
|
|||
.. _installing-linux:
|
||||
|
||||
Installing the Linux Desktop Client
|
||||
===================================
|
||||
|
||||
The ownCloud Desktop Client is provided for a wide range of Linux
|
||||
distributions. The following table provides a list of Linux operating systems
|
||||
and the specific distributions on which you can install the Desktop Client.
|
||||
|
||||
+------------------+-------------------------+
|
||||
| Operating System | Distribution |
|
||||
+==================+=========================+
|
||||
| CentOS (Redhat) | - Red Hat RHEL-6 |
|
||||
| | - CentOS CentOS-6 |
|
||||
+------------------+-------------------------+
|
||||
| Debian | - Debian 7.0 |
|
||||
| | - Fedora 19 |
|
||||
| | - Fedora 20 |
|
||||
+------------------+-------------------------+
|
||||
| openSUSE | - openSUSE |
|
||||
| | - Factory PPC |
|
||||
| | - openSUSE Factory ARM |
|
||||
| | - openSUSE Factory |
|
||||
| | - openSUSE 13.1 Ports |
|
||||
| | - openSUSE 13.1 |
|
||||
| | - openSUSE 12.3 Ports |
|
||||
| | - openSUSE 12.3 |
|
||||
| | - openSUSE 12.2 |
|
||||
+------------------+-------------------------+
|
||||
| SUSE (SLE) | - SLE 11 SP3 |
|
||||
+------------------+-------------------------+
|
||||
| Ubuntu | - xUbuntu 14.04 |
|
||||
| | - xUbuntu 13.10 |
|
||||
| | - xUbuntu 12.10 |
|
||||
| | - xUbuntu 12.04 |
|
||||
+------------------+-------------------------+
|
||||
|
||||
General instructions for how to install the ownCloud Desktop Client on any
|
||||
supported Linux distribution can be found on the `ownCloud download page
|
||||
<http://software.opensuse.org/download/package?project=isv:ownCloud:desktop&package=owncloud-client>`_.
|
||||
|
||||
Linux Installation Methods
|
||||
--------------------------
|
||||
|
||||
You can install the ownCloud Desktop Client using either of the following three methods:
|
||||
|
||||
- One Click Install (openSUSE and SUSE SLE distributions only) — Installs the
|
||||
ownCloud Desktop using a bundled installation package.
|
||||
- Adding the ownCloud package repository — Installs the ownCloud Desktop client
|
||||
using a Linux terminal and keeps it up to date using the distribution's
|
||||
package manager.
|
||||
|
||||
.. note::
|
||||
|
||||
Manual command line installation requires that you perform the installation as root.
|
||||
|
||||
- Binary package — Installs the ownCloud Desktop Client using a raw binary package.
|
||||
|
||||
Installing the Desktop Client on Redhat or CentOS Linux Operating Systems
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
To install the ownCloud Desktop Client on a Redhat or CentOS operating system manually:
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
|
||||
2. Specify the directory in which you want to install the client.
|
||||
|
||||
``cd /etc/yum.repos.d/``
|
||||
|
||||
3. Choose and download the client for your specific distribution:
|
||||
|
||||
* Red Hat RHEL-6: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/RedHat_RHEL-6/isv:ownCloud:desktop.repo``
|
||||
* CentOS CentOS-6: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/CentOS_CentOS-6/isv:ownCloud:desktop.repo``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``yum install owncloud-client``
|
||||
|
||||
5. After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
||||
|
||||
**Installing the Desktop Client on Debian 7.0 Linux Operating Systems Manually**
|
||||
|
||||
To install the ownCloud Desktop Client on the Debian 7.0 distribution manually:
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
|
||||
2. Download the client.
|
||||
|
||||
``echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/Debian_7.0/ /' >> /etc/apt/sources.list.d/owncloud-client.list``
|
||||
|
||||
3. Download the package lists from any repositories and updates them to ensure the latest package versions and their dependencies.
|
||||
|
||||
``apt-get update``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``apt-get install owncloud-client``
|
||||
|
||||
5. (Optional) Download the apt-key for the Debian repository
|
||||
|
||||
``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/Debian_7.0/Release.key``
|
||||
|
||||
6. After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
||||
|
||||
Installing the Desktop Client on Fedora Linux Operating Systems
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
To install the ownCloud Desktop Client on the Fedora operating system manually:
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
2. Specify the directory in which you want to install the client.
|
||||
|
||||
cd /etc/yum.repos.d/
|
||||
|
||||
3. Choose and download the client for your specific distribution
|
||||
|
||||
* Fedora 19: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/Fedora_19/isv:ownCloud:desktop.repo``
|
||||
* Fedora 20: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/Fedora_20/isv:ownCloud:desktop.repo``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``yum install owncloud-client``
|
||||
|
||||
5. After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
||||
|
||||
Installing the Desktop Client on openSUSE Linux Operating Systems
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
To install the ownCloud Desktop Client on the openSUSE operating system manually:
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
|
||||
2. Choose and download the client for your specific distribution:
|
||||
|
||||
* Factory PPC: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_Factory_PPC/isv:ownCloud:desktop.repo``
|
||||
* **Factory ARM**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_Factory_ARM/isv:ownCloud:desktop.repo``
|
||||
* **Factory**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_Factory/isv:ownCloud:desktop.repo``
|
||||
* **13.1 Ports**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_13.1_Ports/isv:ownCloud:desktop.repo``
|
||||
* **13.1**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_13.1/isv:ownCloud:desktop.repo``
|
||||
* **12.3 Ports**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_12.3_Ports/isv:ownCloud:desktop.repo``
|
||||
* **12.3**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_12.3/isv:ownCloud:desktop.repo``
|
||||
* **12.2**: ``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/openSUSE_12.2/isv:ownCloud:desktop.repo``
|
||||
|
||||
3. Download any package metadata from the medium and store it in local cache.
|
||||
|
||||
``zypper refresh``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``zypper install owncloud-client``
|
||||
|
||||
5. After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
||||
|
||||
Installing the Desktop Client on SLE Linux Operating Systems
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
To install the ownCloud Desktop Client on the SUSE Linux Enterprise (SLE) operating system.
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
|
||||
2. Download the client.
|
||||
|
||||
``zypper addrepo http://download.opensuse.org/repositories/isv:ownCloud:desktop/SLE_11_SP3/isv:ownCloud:desktop.repo``
|
||||
|
||||
3. Download any package metadata from the medium and store it in local cache.
|
||||
|
||||
``zypper refresh``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``zypper install owncloud-client``
|
||||
|
||||
5. After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
||||
|
||||
Installing the Desktop Client on Ubuntu Linux Operating Systems
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
To install the ownCloud Desktop Client on the Ubuntu operating system:
|
||||
|
||||
1. Open a Linux terminal window.
|
||||
|
||||
2. Choose and download the client for your specific distribution:
|
||||
|
||||
* **xUbuntu 14.04**: ``sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/xUbuntu_14.04/ /' >> /etc/apt/sources.list.d/owncloud-client.list"``
|
||||
* **xUbuntu 13.10**: ``sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/xUbuntu_13.10/ /' >> /etc/apt/sources.list.d/owncloud-client.list"``
|
||||
* **xUbuntu 12.10**: ``sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/xUbuntu_12.10/ /' >> /etc/apt/sources.list.d/owncloud-client.list"``
|
||||
* **xUbuntu 12.04**: ``sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/xUbuntu_12.04/ /' >> /etc/apt/sources.list.d/owncloud-client.list"``
|
||||
|
||||
3. Download the package lists from any repositories and updates them to ensure the latest package versions and their dependencies.
|
||||
|
||||
``apt-get update``
|
||||
|
||||
4. Install the client.
|
||||
|
||||
``sudo apt-get install owncloud-client``
|
||||
|
||||
5. (Optional) Download the apt-key for the Ubuntu repository:
|
||||
|
||||
* **xUbuntu 14.04**: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/xUbuntu_14.04/Release.key``
|
||||
* **xUbuntu 13.10**: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/xUbuntu_13.10/Release.key``
|
||||
* **xUbuntu 12.10**: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/xUbuntu_12.10/Release.key``
|
||||
* **xUbuntu 12.04**: ``wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/xUbuntu_12.04/Release.key``
|
||||
|
||||
6. (Optional) Add the apt key.
|
||||
|
||||
``sudo apt-key add - < Release.key``
|
||||
|
||||
7. After the installation completes, go to `Setting Up the ownCloud Desktop Client`_.
|
4
doc/installing-macosx.rst
Normal file
|
@ -0,0 +1,4 @@
|
|||
.. _installing-macosx:
|
||||
|
||||
Installing the MAC OSX Desktop Client
|
||||
=====================================
|
102
doc/installing-windows.rst
Normal file
|
@ -0,0 +1,102 @@
|
|||
.. _installing-windows:
|
||||
|
||||
Installing the Windows Desktop Client
|
||||
=====================================
|
||||
|
||||
The ownCloud desktop client for Windows is provided as a Nullsoft Scriptable Install System (NSIS) setup file for machine-wide installation.
|
||||
|
||||
To install the ownCloud desktop client:
|
||||
|
||||
1. Access the ownCloud website.
|
||||
|
||||
The ownCloud web page opens.
|
||||
|
||||
.. image:: images/oc_website.png
|
||||
|
||||
ownCloud Web Page
|
||||
|
||||
2. Select Products > Desktop Clients from the website menu.
|
||||
|
||||
The Desktop Client download page opens.
|
||||
|
||||
.. image:: images/oc_client_download_options.png
|
||||
|
||||
Desktop client download selections
|
||||
|
||||
3. Click the 'Download for Windows' option.
|
||||
The Desktop Client download page opens.
|
||||
|
||||
.. image:: images/oc_client_windows_download.png
|
||||
|
||||
ownCloud Windows Client Download
|
||||
|
||||
4. Click the 'download' button.
|
||||
|
||||
The Microsoft Windows client download begins. Depending on your browser
|
||||
settings, the client installation file might launch automatically.
|
||||
|
||||
5. Once the download completes, locate the client installation file in your system Downloads folder.
|
||||
|
||||
6. Double-click the client installation file to start the download.
|
||||
|
||||
The Open File - Security Warning dialog box opens.
|
||||
|
||||
.. image:: images/security_warning_windows.png
|
||||
|
||||
Open File - Security Warning dialog box
|
||||
|
||||
7. Click 'Run' in the dialog box to begin the installation.
|
||||
|
||||
On systems running virus protection software, you might have to verify
|
||||
that you want to install the ownCloud Desktop Client software.
|
||||
|
||||
8. Click 'Yes' to continue with the software installation.
|
||||
|
||||
The ownCloud Setup Wizard window opens.
|
||||
|
||||
.. image:: images/client_setup_wizard_main.png
|
||||
|
||||
ownCloud Setup Wizard Window
|
||||
|
||||
9. Click 'Next' to continue.
|
||||
|
||||
The Choose Components window opens.
|
||||
|
||||
.. image:: images/client_setup_wizard_components.png
|
||||
|
||||
Choose Components Window
|
||||
|
||||
10. Choose the components that you want to install for the Desktop Client.
|
||||
|
||||
All relevant components for your platform are selected by default.
|
||||
However, you can choose to exlude different components from the installation.
|
||||
|
||||
11. Click Next to continue.
|
||||
|
||||
The Choose Install Location window opens.
|
||||
|
||||
.. image:: images/client_setup_wizard_location.png
|
||||
|
||||
Choose Install Location window
|
||||
|
||||
12. Verify the destination folder for the Desktop Client installation and then click Install.
|
||||
|
||||
The Installing window opens.
|
||||
|
||||
.. image:: images/client_setup_wizard_install_progress.png
|
||||
|
||||
Installing window
|
||||
|
||||
13. Once the installation completes, click 'Next' to continue.
|
||||
|
||||
The Setup Wizard Completion window opens.
|
||||
|
||||
.. image:: images/client_setup_wizard_install_finish.png
|
||||
|
||||
Completion window
|
||||
|
||||
You can choose to launch the Desktop Client from this window or launch the application at another time.
|
||||
|
||||
14. Click 'Finish' to complete the installation.
|
||||
|
||||
After the installation completes, go to Setting Up the ownCloud Desktop Client.
|
13
doc/installing.rst
Normal file
|
@ -0,0 +1,13 @@
|
|||
Installing the Synchronization Client
|
||||
=====================================
|
||||
|
||||
The latest version of the ownCloud Synchronization Client can be obtained from
|
||||
the `ownCloud Website <http://www.owncloud.com>`_. You can download and install
|
||||
the client on Windows, MAC OSX, and various Linux software distrubutions. The
|
||||
following sections describe specific support and installation procedures for
|
||||
the different software platforms:
|
||||
|
||||
- :ref:`installing-windows`
|
||||
- :ref:`installing-macosx`
|
||||
- :ref:`installing-linux`
|
||||
|
|
@ -1,32 +1,14 @@
|
|||
Introduction
|
||||
============
|
||||
|
||||
The ownCloud Sync Client is a desktop program installed on a user’s computer.
|
||||
It allows a user to specify one or more directories on the local machine to
|
||||
sync to the ownCloud server. It allows the user to always have the latest
|
||||
files wherever they may be. When a change is made to the file on the
|
||||
computer, it will sync to the ownCloud server via the sync client.
|
||||
Available for Windows, MAC OS X, and various Linux distributions, the ownCloud
|
||||
Sync client is a desktop program installed on your computer. The client enables
|
||||
you to:
|
||||
|
||||
The ownCloud Sync Client is available for Windows, MAC OS X, and various
|
||||
Linux distributions.
|
||||
- Specify one or more directories on your computer that you want to synchronize
|
||||
to the ownCloud server.
|
||||
- Always have the latest files synchronized, wherever they are located.
|
||||
|
||||
Obtaining the Client
|
||||
--------------------
|
||||
Changes made to any synchronized file on the computer are automatically made to
|
||||
the files on the ownCloud server using the sync client.
|
||||
|
||||
The latest version of the Client can be obtained on the ownCloud web site.
|
||||
|
||||
ownCloud client for **Windows** is provided as a NSIS-based setup file for
|
||||
machine-wide install. Installing the ownCloud client on **Mac OS** follows
|
||||
the normal app bundle installation pattern:
|
||||
|
||||
1. Download the installation file: Click ``ownCloud-x.y.z.dmg``, a window with
|
||||
the ownCloud icon opens.
|
||||
2. In that window, drag the ownCloud application into the ``Applications``
|
||||
folder.
|
||||
3. On the right hand side From ``Applications``, choose ``ownCloud``.
|
||||
|
||||
The ownCloud client is also provided as in a convenient repository for a wide
|
||||
range of popular **Linux distributions**.
|
||||
|
||||
Supported distributions are Fedora, openSUSE, Ubuntu and Debian.
|
||||
To support other distributions, a is required, see :ref:`building-label`
|
||||
|
|
313
doc/navigating.rst
Normal file
|
@ -0,0 +1,313 @@
|
|||
Using the Synchronization Client
|
||||
================================
|
||||
|
||||
.. index:: navigating, usage
|
||||
|
||||
The ownCloud Client remains in the background and is visible as an icon in the
|
||||
system tray (Windows, KDE), status bar (MAC OS X), or notification area
|
||||
(Ubuntu).
|
||||
|
||||
.. image:: images/icon.png
|
||||
|
||||
**ownCloud Desktop Client icon**
|
||||
|
||||
Using the Desktop Client Menu
|
||||
-----------------------------
|
||||
|
||||
A right click on the icon (left click on Ubuntu and Mac OS X) provides the
|
||||
following menu:
|
||||
|
||||
.. image:: images/menu.png
|
||||
|
||||
**ownCloud Desktop Client menu**
|
||||
|
||||
The Desktop Client menu provides the following options:
|
||||
|
||||
* ``Open ownCloud in browser``: Launches the ownCloud WEB interface.
|
||||
* ``Open folder 'ownCloud'``: Opens the ownCloud local folder. If you have defined multiple synchronization targets, the window displays each local folder.
|
||||
* **Disk space indicator**: Indicates the amount of space currently used on the server.
|
||||
* Operation indicator: Displays the status of the current synchronization process or indicates ``Up to date`` if the server and client are in sync.
|
||||
* **Recent Changes**: Displays the last six files modified by the synchronization operations and provides access to the current synchronization status listing all changes since the last restart of the ownCloud client.
|
||||
* ``Settings...``: Provides access to the settings menu.
|
||||
* ``Help``: Opens a browser to display ownCloud Desktop Client Guide.
|
||||
* ``Sign out``: Disables the client from continued synchronizations.
|
||||
* ``Quit ownCloud``: Quits the ownCloud Client, ending any currently running
|
||||
synchronizations.
|
||||
|
||||
Using the Account Settings Window
|
||||
---------------------------------
|
||||
|
||||
.. index:: account settings, user, password, Server URL
|
||||
|
||||
The ``Account`` window provides a summary for general settings associated with the ownCloud account. This window enalbes you to manage any synchronized folders in the account and enables you to modify them.
|
||||
|
||||
To access and modify the account settings:
|
||||
|
||||
.. image:: images/settings_account.png
|
||||
:scale: 50 %
|
||||
|
||||
The fields and options in this window include:
|
||||
|
||||
* ``Connected to <ownCloud instance> as <user>`` field: Indicates the ownCloud server to which the client is synchronizing and the user account on that server.
|
||||
|
||||
* ``Add Folder...`` button: Provides the ability to add another folder to the synchronization process (see ``Adding a Folder``).
|
||||
|
||||
* ``Pause/Resume`` button: Pauses the current sync (or prevents the client from starting a new sync) or resumes the sync process.
|
||||
|
||||
* ``Remove`` button: Removes the selected folder from the sync process. This button is used when you want to synchronize only a few folders and not the root folder. If only the root folder is available, you must first remove the root from the synchronization and then add individual folders that you want to synchronize as desired.
|
||||
|
||||
* ``Storage Usage`` field: Indicates the storage utilization on the ownCloud server.
|
||||
|
||||
* ``Edit Ignored Files`` button: Launches the Ignored Files Editor.
|
||||
|
||||
* ``Modify Account`` button: Enables you to change the ownCloud server to which you are synchronizing. This option launches the ``Setting up an Account`` windows (See ??).
|
||||
|
||||
|
||||
Adding a Folder
|
||||
^^^^^^^^^^^^^^^
|
||||
|
||||
The ``Add a Folder ...`` button enables you to add a new folder to the syncrhonization process.
|
||||
|
||||
To add a new folder:
|
||||
|
||||
1. Click the ``Add a Folder ...`` button in the Account window.
|
||||
|
||||
The ``Add Folder...`` window opens
|
||||
|
||||
.. image:: images/folderwizard_local.png
|
||||
:scale: 50 %
|
||||
|
||||
**``Add Folder...`` window (local folder)**
|
||||
|
||||
2. Specify a *unique* path and alias name to the folder or use the ``Choose...`` button to locate the new folder on your system to which you want to synchronize.
|
||||
|
||||
..note:: Nested synchronizations are not supported. In other words, you
|
||||
cannot add a folder that is already contained within another synchronized
|
||||
folder. In addition, you cannot add a higher level (parent) folder that
|
||||
contains a folder to which you are already synchronizing. By default, the
|
||||
ownCloud Set Up Wizard syncrhonizes your entire ownCloud account to the root
|
||||
folder of the ownCloud server. Due to this default setup, you must first remove
|
||||
the top-level folder prior to specifying new synchronizations.
|
||||
|
||||
3. Click 'Next' to continue.
|
||||
|
||||
A window opens prompting you to select a remote destination folder on the
|
||||
ownCloud server to which you want to synchronize.
|
||||
|
||||
.. image:: images/folderwizard_remote.png
|
||||
:scale: 50 %
|
||||
|
||||
**``Add Folder...`` window (remote destination)**
|
||||
|
||||
4. Select a folder on the ownCloud server to which you want to synchronize your newly added folder.
|
||||
|
||||
..note:: A server folder can only be synchronized with a particular client once.
|
||||
If you attempt to sync the root directory, you cannot sync with other folders
|
||||
on the server. Similarly, if you sync with folder ``/a``, you cannot create
|
||||
another sync with ``/a/b``, since ``b`` is already being synched.
|
||||
|
||||
Editing Ignored Files
|
||||
^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
The :guilabel:`Ignored Files Editor` provides a list of preconfigured files
|
||||
that are ignored (that is, not synchronized) by the client and server during
|
||||
synchronizations. The Ignored Files Editor enables you to add patterns for
|
||||
files or directories that you want to exclude from the synchronization process.
|
||||
In addition to using standard characters, the Ignored Files Editor enables you
|
||||
to use wild cards (for example, using an asterisk ‘*’ to indicate multiple
|
||||
characters or a question mark ‘?’ to incidate a single character).
|
||||
|
||||
For additional information about this editor, see `Using the Ignored Files Editor`_
|
||||
|
||||
Using the Activity Settings Window
|
||||
----------------------------------
|
||||
|
||||
.. index:: activity, recent changes, sync activity
|
||||
|
||||
The Activity window provides an in-depth account of recent synchronization
|
||||
activity. It shows files that have not been synchronized because they are on
|
||||
the ignored files list or because they cannot be synced in a cross-platform
|
||||
manner due to containing special characters that cannot be stored on certain
|
||||
file systems.
|
||||
|
||||
.. image:: images/settings_activity.png
|
||||
:scale: 50 %
|
||||
|
||||
**Activity settings window**
|
||||
|
||||
You can open the Activity window in one of the following ways:
|
||||
|
||||
- Click 'Activity' in the left frame of the ownCloud Settings window.
|
||||
|
||||
- Invoke the window from the ownCloud Desktop Client menu by selecting ``Recent
|
||||
Changes`` > ``Details...``. (See Using the Desktop Client Menu.)
|
||||
|
||||
Using the General Settings Window
|
||||
---------------------------------
|
||||
|
||||
.. index:: general settings, auto start, startup, desktop notifications
|
||||
|
||||
The General settings window enables you to set general settings for the
|
||||
ownCloud Desktop Client and provides information about the software version,
|
||||
its creator, and the existance of any updates.
|
||||
|
||||
.. image:: images/settings_general.png
|
||||
:scale: 50 %
|
||||
|
||||
**General settings window**
|
||||
|
||||
The settings and information contained in this window are as follows:
|
||||
|
||||
* ``Launch on System Startup`` checkbox: Provides the option to check (enable)
|
||||
or uncheck (disable) whether the ownCloud Desktop Client launches upon system
|
||||
startup. By default, this option is enabled (checked)once you have configured
|
||||
your account.
|
||||
|
||||
* ``Show Desktop Nofications`` checkbox: Provides the option to check (enable)
|
||||
or uncheck (disable) bubble notifications alerting you as to when a set of
|
||||
synchronization operations is performed.
|
||||
|
||||
* ``Use Monochrome Icons`` checkbox: Provides the option to check (enable) or
|
||||
uncheck (disable) the use of monochrome (visually less obtrusive) icons.
|
||||
|
||||
.. note:: This option can be useful on MAC OSX platforms.
|
||||
|
||||
* ``About`` field: Provides information about the software authors along with
|
||||
pertinent build conditions.
|
||||
|
||||
.. note:: Information in this field can be valuable when submitting a support request.
|
||||
|
||||
* ``Updates`` field: Provides information about any available updates for the
|
||||
ownCloud Desktop Client.
|
||||
|
||||
Using the Network Settings Window
|
||||
---------------------------------
|
||||
|
||||
.. index:: proxy settings, SOCKS, bandwith, throttling, limiting
|
||||
|
||||
The Network settings window enables you to define network proxy settings as
|
||||
well as limit the download and upload bandwidth utilization of file
|
||||
synchronizations.
|
||||
|
||||
.. image:: images/settings_network.png
|
||||
:scale: 50 %
|
||||
|
||||
**Network settings window**
|
||||
|
||||
Specifying Proxy Settings
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
A proxy server is a server (for example, a computer system or an application)
|
||||
that functions as an intermediary contact for requests from clients that are
|
||||
seeking resources from other servers. For the ownCloud Desktop Client, you can
|
||||
define the following proxy settings:
|
||||
|
||||
* ``No Proxy`` option: Specifies that the ownCloud Client circumvent the default proxy configured on the system.
|
||||
* ``Use system proxy`` option: Default setting. Follows the systems proxy
|
||||
settings. On Linux systems, this setting uses the value of the variable
|
||||
``http_proxy``.
|
||||
* ``Specify proxy manually as`` option: Enables you to specify
|
||||
the following custom proxy settings:
|
||||
- ``HTTP(S)``: Used when you are required to use an HTTP(S) proxy server (for example, Squid or Microsoft Forefront TMG).
|
||||
- ``SOCKSv5``: Typically used in special company LAN setups, or in combination with the OpenSSH
|
||||
dynamic application level forwarding feature (see ``ssh -D``).
|
||||
- ``Host``: Host name or IP address of the proxy server along with the port number. HTTP proxies
|
||||
typically listen over Ports 8080 (default) or 3128. SOCKS servers typically listen over port 1080.
|
||||
* ``Proxy Server requires authentication`` checkbox: Provides the option to check (enable/require) or
|
||||
uncheck (disable/not require) proxy server authentication. When not checked, the proxy server must
|
||||
be configured to allow anonymous usage. When checked, a proxy server username and password is required.
|
||||
|
||||
Bandwidth Limiting
|
||||
^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Synchronization of files between a client and server can utilized a lot of
|
||||
bandwidth. Bandwidth limiting can assist in shaping the total download or
|
||||
upload bandwidth (or both) of your client/server connection to a more
|
||||
manageable level. By limiting your bandwidth usage, you can maintain free
|
||||
bandwidth for other applications to use.
|
||||
|
||||
The ownCloud Desktop Client enables you to limit (throttle) the bandwidth usage
|
||||
for both file downloads and file uploads. The Download Bandwidth field (for
|
||||
data flowing from the ownCloud server to the client) provides the following
|
||||
options:
|
||||
|
||||
- ``No limit`` option: The default setting for the client; specifies that there
|
||||
are no limit settings on the amount of data downloaded from the server.
|
||||
|
||||
- ``Limit to <value> KBytes/s`` option: Limits (throttles) the bandwidth to
|
||||
a customized value (in KBytes/second).
|
||||
|
||||
The Upload Bandwidth field (for data flowing from the ownCloud client to the
|
||||
server) provides the following options:
|
||||
|
||||
- ``No limit`` option: The default setting for the client; specifies that there
|
||||
are no limit settings on the amount of data downloaded from the server.
|
||||
|
||||
- ``Limit automatically``: When enabled, the ownCloud client surrenders
|
||||
available bandwidth to other applications. Use this option if there are
|
||||
issues with real time communication (for example, the use of IP phone or live
|
||||
streaming) in conjunction with the ownCloud Client.
|
||||
|
||||
- ``Limit to <value> KBytes/s`` option: Limits (throttles) the bandwidth to a
|
||||
customized value (in KBytes/second).
|
||||
|
||||
|
||||
.. _ignoredFilesEditor-label:
|
||||
|
||||
Using the Ignored Files Editor
|
||||
------------------------------
|
||||
|
||||
.. index:: ignored files, exclude files, pattern
|
||||
|
||||
You might have some files or directories that you do not want to backup and
|
||||
store on the server. To identify and exclude these files or directories, you
|
||||
can use the *Ignored Files Editor* that is embedded in the ownCloud Desktop
|
||||
Client.
|
||||
|
||||
.. image:: images/ignored_files_editor.png
|
||||
:scale: 50%
|
||||
|
||||
Ignored Files Editor window
|
||||
|
||||
The :guilabel:`Ignored Files Editor` enables you to define customized patterns that the
|
||||
ownCloud Client uses to identify files and directories that you want to exclude
|
||||
from the synchronization process. For your convenience, the editor is
|
||||
pre-populated with a default list of typically ignore patterns. These patterns
|
||||
are contained in a system file (typically ``sync-exclude.lst``) located in the
|
||||
ownCloud Client application directory. You cannot modify these pre-populated
|
||||
patterns directly from the editor. However, if necessary, you can hover over
|
||||
any pattern in the list to show the path and filename associated with that
|
||||
pattern, locate the file, and edit the ``sync-exclude.lst`` file.
|
||||
|
||||
.. note:: Modifying the global exclude definition file might render the client
|
||||
unusable or result in undesired behavior.
|
||||
|
||||
Each line in the editor contains an ignore pattern string. When creating custom
|
||||
patterns, in addition to being able to use normal characters to define an
|
||||
ignore pattern, you can use wildcards characters for matching values. As an
|
||||
example, you can use an asterisk (``*``) to idenfify an arbitrary number of
|
||||
characters or a question mark (``?``) to identify a single character.
|
||||
|
||||
Patterns that end with a slash character (``/``) are applied to only directory
|
||||
components of the path being checked.
|
||||
|
||||
.. note:: Custom entries are currently not validated for syntactical
|
||||
correctness by the editor, but might fail to load correctly.
|
||||
|
||||
Each pattern string in the list is preceded by a checkbox. When the check box
|
||||
contains a check mark, in addition to ignoring the file or directory component
|
||||
matched by the pattern, any matched files are also deemed "fleeting metadata"
|
||||
and removed by the client.
|
||||
|
||||
In addition to excluding files and directories that use patterns defined in
|
||||
this list:
|
||||
|
||||
- The ownCloud Client always excludes files containing characters that cannot
|
||||
be synchronized to other file systems.
|
||||
|
||||
- As of ownCloud Desktop Client version 1.5.0, files are removed that cause
|
||||
individual errors three times during a synchronization. However, the client
|
||||
provides the option of retrying a synchronization three additional times on
|
||||
files that produce errors.
|
||||
|
||||
For more detailed information see :ref:`ignored-files-label`.
|
|
@ -1 +1 @@
|
|||
Subproject commit 2c3e584b2356dc4324e6e0720b7aa908aaa480a3
|
||||
Subproject commit c612df399e3c775a2f9db1dc5e39d25920ab467b
|
|
@ -1,24 +1,23 @@
|
|||
When invoking the client from the command line, the following options are supported:
|
||||
|
||||
``-h``, ``--help``
|
||||
shows all the below options (opens a window on Windows)
|
||||
Displays all the options below or, when used on Windows, opens a window displaying all options.
|
||||
|
||||
``--logwindow``
|
||||
open a window to show log output.
|
||||
Opens a window displaying log output.
|
||||
|
||||
``--logfile`` `<filename>`
|
||||
write log output to file <filename>. To write to stdout, specify `-`
|
||||
as filename
|
||||
Write log output to the file specified. To write to stdout, specify `-` as the filename.
|
||||
|
||||
``--logdir`` `<name>`
|
||||
write each sync log output in a new file in directory <name>
|
||||
Writes each synchronization log output in a new file in the specified directory.
|
||||
|
||||
``--logexpire`` `<hours>`
|
||||
removes logs older than <hours> hours. (to be used with --logdir)
|
||||
Removes logs older than the value specified (in hours). This command is used with ``--logdir``.
|
||||
|
||||
``--logflush``
|
||||
flush the log file after every write.
|
||||
Clears (flushes) the log file after each write action.
|
||||
|
||||
``--confdir`` `<dirname>`
|
||||
Use the given configuration directory.
|
||||
Uses the specified configuration directory.
|
||||
|
||||
|
|
|
@ -10,13 +10,9 @@ SYNOPSIS
|
|||
|
||||
DESCRIPTION
|
||||
===========
|
||||
ownCloud is a file synchronisation desktop utility based on mirall.
|
||||
It synchronizes files on your local machine with an ownCloud Server. If you
|
||||
make a change to the files on one computer, it will flow across the others
|
||||
using this desktop sync clients.
|
||||
The ownCloud Client is a file synchronization desktop utility based on mirall. It synchronizes files on your local computer, tablet, or handheld device with an ownCloud Server. If you make a change to the files on one device, the change is propagated to all other syncrhonized devices using the desktop synchronization clients.
|
||||
|
||||
Normally you start the client by click on the desktop icon or start from the
|
||||
application menu. After starting an ownCloud icon appears in the system tray.
|
||||
Normally, you start the client by clicking on the desktop icon or by starting it from the client application menu. After starting, an ownCloud icon appears in the computer system tray or on your tablet or handheld device.
|
||||
|
||||
Options
|
||||
=======
|
||||
|
|
|
@ -9,38 +9,38 @@ SYNOPSIS
|
|||
|
||||
DESCRIPTION
|
||||
===========
|
||||
owncloudcmd is the command line tool for the ownCloud file synchronisation
|
||||
desktop utility, based on mirall.
|
||||
owncloudcmd is the command line tool used for the ownCloud file synchronization
|
||||
desktop utility. This command line tool is based on mirall.
|
||||
|
||||
Contrary to the :manpage:`owncloud(1)` GUI client, `owncloudcmd` will only
|
||||
perform a single sync run and then exit. It thus replaces the `ocsync` binary
|
||||
used for the same purpose in earlier releases.
|
||||
Contrary to the :manpage:`owncloud(1)` GUI client, `owncloudcmd` only performs
|
||||
a single sync run and then exits. In so doing, `owncloudcmd` replaces the
|
||||
`ocsync` binary used for the same purpose in earlier releases.
|
||||
|
||||
A sync run will sync a single local directory with a WebDAV share on a
|
||||
A *sync run* synchronizes a single local directory using a WebDAV share on a
|
||||
remote ownCloud server.
|
||||
|
||||
To invoke the command line client, provide the local and the remote repository:
|
||||
The first parameter is the local directory. The second parameter is
|
||||
the server URL.
|
||||
|
||||
.. note:: Prior to 1.6, the tool only accepted ``owncloud://`` or ``ownclouds://``
|
||||
in place of ``http://`` and ``https://`` as a scheme. See ``Examples``
|
||||
for details.
|
||||
.. note:: Prior to the 1.6 release of owncloudcmd, the tool only accepted
|
||||
``owncloud://`` or ``ownclouds://`` in place of ``http://`` and ``https://`` as
|
||||
a scheme. See ``Examples`` for details.
|
||||
|
||||
OPTIONS
|
||||
=======
|
||||
``--confdir`` `PATH`
|
||||
The configuration dir where `csync.conf` is located
|
||||
Specifies the configuration directory where `csync.conf` is located.
|
||||
|
||||
``--silent``
|
||||
Don't give verbose log output
|
||||
Inhibits verbose log output.
|
||||
|
||||
``--httpproxy http://[user@pass:]<server>:<port>``
|
||||
Use ``server`` as HTTP proxy
|
||||
Uses ``server`` as HTTP proxy.
|
||||
|
||||
Example
|
||||
=======
|
||||
To sync the ownCloud directory ``Music`` to the local directory ``media/music``
|
||||
To synchronize the ownCloud directory ``Music`` to the local directory ``media/music``
|
||||
through a proxy listening on port ``8080`` on the gateway machine ``192.168.178.1``,
|
||||
the command line would be::
|
||||
|
||||
|
@ -49,7 +49,7 @@ the command line would be::
|
|||
https://server/owncloud/remote.php/webdav/Music
|
||||
|
||||
|
||||
Using the legacy scheme, it would look like this::
|
||||
Using the legacy scheme, it would be::
|
||||
|
||||
$ owncloudcmd --httpproxy http://192.168.178.1:8080 \
|
||||
$HOME/media/music \
|
||||
|
|
|
@ -1,44 +1,43 @@
|
|||
The ownCloud Client packages come with a command line client which
|
||||
can be used to synchronize ownCloud files to client machines. The
|
||||
command line client is called ``owncloudcmd``.
|
||||
The ownCloud Client packages contain a command line client that can be used to
|
||||
synchronize ownCloud files to client machines. The command line client is
|
||||
called ``owncloudcmd``.
|
||||
|
||||
owncloudcmd performs a single sync run and then exits.
|
||||
That means that it processes the differences between client- and
|
||||
server directory and propagates the files to get both repositories
|
||||
on the same status. Contrary to the GUI based client, it does not
|
||||
repeat syncs on its own. It does also not monitor for file system
|
||||
changes.
|
||||
owncloudcmd performs a single *sync run* and then exits the synchronization
|
||||
process. In this manner, owncloudcmd processes the differences between client
|
||||
and server directories and propagates the files to bring both repositories to
|
||||
the same state. Contrary to the GUI-based client, owncloudcmd does not repeat
|
||||
synchronizations on its own. It also does not monitor for file system changes.
|
||||
|
||||
To invoke the command line client, the user has to provide the local
|
||||
and the remote repository urls::
|
||||
To invoke the owncloudcmd, you must provide the local and the remote repository
|
||||
urls using the following command::
|
||||
|
||||
owncloudcmd [OPTIONS...] sourcedir owncloudurl
|
||||
|
||||
where ``sourcedir`` is the local directory and ``owncloudurl`` is
|
||||
the server url.
|
||||
the server URL.
|
||||
|
||||
.. note:: Prior to 1.6, the tool only accepted ``owncloud://`` or
|
||||
``ownclouds://`` in place of ``http://`` and ``https://``
|
||||
as a scheme. See ``Examples`` for details.
|
||||
.. note:: Prior to the 1.6 version of owncloudcmd, the tool only accepted
|
||||
``owncloud://`` or ``ownclouds://`` in place of ``http://`` and ``https://`` as
|
||||
a scheme. See ``Examples`` for details.
|
||||
|
||||
These are other comand line switches supported by owncloudcmd:
|
||||
Other comand line switches supported by owncloudcmd include the following:
|
||||
|
||||
``--silent``
|
||||
Don't give verbose log output
|
||||
- ``--silent``
|
||||
Supresses verbose log output.
|
||||
|
||||
``--confdir`` `PATH`
|
||||
Fetch or store configuration in this custom config directory
|
||||
- ``--confdir`` `PATH`
|
||||
Fetches or stores configuration in the specified configuration directory.
|
||||
|
||||
``--httpproxy http://[user@pass:]<server>:<port>``
|
||||
Use ``server`` as HTTP proxy
|
||||
- ``--httpproxy http://[user@pass:]<server>:<port>``
|
||||
Uses the specified ``server`` as the HTTP proxy.
|
||||
|
||||
Credential Handling
|
||||
~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
By default, owncloudcmd reads the client configuration and uses the credentials
|
||||
of the GUI sync client. If no client was configured or to use a different user
|
||||
to sync, the user password setting can be specified with the usual URL pattern,
|
||||
for example::
|
||||
of the GUI syncrhonization client. If no client is configured, or if you choose
|
||||
to use a different user to synchronize, you can specify the user password
|
||||
setting with the usual URL pattern. For example::
|
||||
|
||||
https://user:secret@192.168.178.2/remote.php/webdav
|
||||
|
||||
|
@ -46,16 +45,16 @@ for example::
|
|||
Example
|
||||
~~~~~~~
|
||||
|
||||
To sync the ownCloud directory ``Music`` to the local directory ``media/music``
|
||||
through a proxy listening on port ``8080`` on the gateway machine ``192.168.178.1``,
|
||||
the command line would be::
|
||||
To synchronize the ownCloud directory ``Music`` to the local directory
|
||||
``media/music`, through a proxy listening on port ``8080``, and on a gateway
|
||||
machine using IP address ``192.168.178.1``, the command line would be::
|
||||
|
||||
$ owncloudcmd --httpproxy http://192.168.178.1:8080 \
|
||||
$HOME/media/music \
|
||||
https://server/owncloud/remote.php/webdav/Music
|
||||
|
||||
|
||||
Using the legacy scheme, it would look like this::
|
||||
Using the legacy scheme, the command line would be::
|
||||
|
||||
$ owncloudcmd --httpproxy http://192.168.178.1:8080 \
|
||||
$HOME/media/music \
|
||||
|
|
|
@ -1,158 +1,223 @@
|
|||
Appendix C: Troubleshooting
|
||||
===========================
|
||||
|
||||
If the client fails to start syncing it basically can have two
|
||||
basic reasons: Either the server setup has a problem or the client
|
||||
has a bug. When reporting bugs, it is crucial to find out what part
|
||||
of the system causes the problem.
|
||||
The following two general issues can result in failed synchronization:
|
||||
|
||||
Identifying basic functionality problems
|
||||
- The server setup is incorrect.
|
||||
- The client contains a bug.
|
||||
|
||||
When reporting bugs, it is helpful if you first determine what part of the
|
||||
system is causing the issue.
|
||||
|
||||
Identifying Basic Functionality Problems
|
||||
----------------------------------------
|
||||
|
||||
:Perform a general ownCloud Server test:
|
||||
A very first check is to verify that you can log on to ownClouds web
|
||||
application. Assuming your ownCloud instance is installed at
|
||||
``http://yourserver.com/owncloud``, type
|
||||
``http://yourserver.com/owncloud/`` into your browsers address bar.
|
||||
:Performing a general ownCloud Server test:
|
||||
The first step in troubleshooting synchronization issues is to verify that
|
||||
you can log on to the ownCloud web application. To verify connectivity to the
|
||||
ownCloud server:
|
||||
|
||||
- Open a browser window and enter the server address to your own server in the location/address bar.
|
||||
|
||||
For example, if your ownCloud instance is installed at URL address
|
||||
``http://yourserver.com/owncloud``, enter ``http://yourserver.com/owncloud/``
|
||||
into your browsers location/address bar.
|
||||
|
||||
If you are not prompted to enter your user name and password, or if you
|
||||
see a red warning box on the page, your server setup is not correct or needs
|
||||
fixes. Please verify that your server installation is working correctly.
|
||||
If you are not prompted for your username and password, or if a red warning
|
||||
box appears on the page, your server setup requires modification. Please verify
|
||||
that your server installation is working correctly.
|
||||
|
||||
:Ensure the WebDAV API is working:
|
||||
If all desktop clients fail to connect to ownCloud, but the access via the
|
||||
web interface works, the problem often is a mis-configuration of the WebDAV
|
||||
API.
|
||||
If all desktop clients fail to connect to the ownCloud Server, but access
|
||||
using the web interface functions properly, the problem is often a
|
||||
misconfiguration of the WebDAV API.
|
||||
|
||||
The ownCloud client uses the built-in WebDAV access of the server content.
|
||||
Verify that you can log on to ownClouds WebDAV server. Assuming your ownCloud
|
||||
instance is installed at ``http://yourserver.com/owncloud``, type
|
||||
``http://yourserver.com/owncloud/remote.php/webdav`` into your browsers
|
||||
address bar.
|
||||
The ownCloud Client uses the built-in WebDAV access of the server content.
|
||||
Verify that you can log on to ownClouds WebDAV server. To verify connectivity
|
||||
with the ownCloud WebDAV server:
|
||||
|
||||
If you are prompted, but the authentication fails even though the credentials
|
||||
your provided are correct, please ensure that your authentication backend
|
||||
is configured properly.
|
||||
- Open a browser window and enter the address to the ownCloud WebDAV server.
|
||||
|
||||
For example, if your ownCloud instance is installed at
|
||||
``http://yourserver.com/owncloud``, your WebDAV server address is
|
||||
``http://yourserver.com/owncloud/remote.php/webdav``.
|
||||
|
||||
If you are prompted for your username and password but, after providing the
|
||||
correct credentials, authentication fails, please ensure that your
|
||||
authentication backend is configured properly.
|
||||
|
||||
:Use a WebDAV command line tool to test:
|
||||
A more sophisticated test is to use a WebDAV command line client and log
|
||||
into the ownCloud WebDAV server, such as a little app called cadaver,
|
||||
available on Linux. It can be used to further verify that the WebDAV server is
|
||||
running properly, for example by performing PROPFIND calls:
|
||||
A more sophisticated test method for troubleshooting syncrhonization issues
|
||||
is to use a WebDAV command line client and log into the ownCloud WebDAV server.
|
||||
One such command line client -- called cadaver -- is available for Linux
|
||||
distributions. You can use this application to further verify that the WebDAV
|
||||
server is running properly using PROPFIND calls.
|
||||
|
||||
As an example, after installing the cadaver app, you can issue the
|
||||
``propget`` command to obtain various properties pertaining to the current
|
||||
directory and also verify WebDAV server connection.
|
||||
|
||||
``propget .`` called within cadaver will return some properties of the current
|
||||
directory and thus be a successful WebDAV connect.
|
||||
|
||||
Isolating other issues
|
||||
----------------------
|
||||
|
||||
If the sync result is unreliable, please ensure that the folder synced with
|
||||
ownCloud is not shared with other syncing apps.
|
||||
Other issues can affect synchronization of your ownCloud files:
|
||||
|
||||
.. note:: Syncing the same directory with ownCloud and other sync software such
|
||||
as Unison, rsync, Microsoft Windows Offline Folders or cloud services
|
||||
such as DropBox or Microsoft SkyDrive is not supported and should
|
||||
not be attempted. In the worst case, doing so can result in data
|
||||
loss.
|
||||
- If you find that the results of the synchronizations are unreliable, please
|
||||
ensure that the folder to which you are synchronizing is not shared with
|
||||
other synchronization applications.
|
||||
|
||||
If some files do not get take a look at the sync protocol. Some files are
|
||||
automatically automatically being ignored because they are system files,
|
||||
others get ignored because their file name contains characters that cannot
|
||||
be represented on certain file systems. See :ref:`_ignored-files-label` for
|
||||
details.
|
||||
.. note:: Synchronizing the same directory with ownCloud and other
|
||||
synchronization software such as Unison, rsync, Microsoft Windows Offline
|
||||
Folders, or other cloud services such as DropBox or Microsoft SkyDrive is not
|
||||
supported and should not be attempted. In the worst case, it is possible that
|
||||
synchronizing folders or files using ownCloud and other synchronization
|
||||
software or services can result in data loss.
|
||||
|
||||
If you are operating your own server and use the local storage backend (the
|
||||
default), make sure that ownCloud has exclusive access to the directory.
|
||||
- If you find that only specific files are not synrchronized, the
|
||||
synchronization protocol might be having an effect. Some files are
|
||||
automatically ignored because they are system files, other files might be
|
||||
ignored because their filename contains characters that are not supported on
|
||||
certain file systems. For more information about ignored files, see
|
||||
:ref:`_ignored-files-label`.
|
||||
|
||||
.. note:: The data directory on the server is exclusive to ownCloud and must
|
||||
not be modified manually.
|
||||
- If you are operating your own server, and use the local storage backend (the
|
||||
default), make sure that ownCloud has exclusive access to the directory.
|
||||
|
||||
If you are using a different backend, you can try to exclude a bug in the
|
||||
backend by reverting to the local backend.
|
||||
.. note:: The data directory on the server is exclusive to ownCloud and must not be modified manually.
|
||||
|
||||
Logfiles
|
||||
--------
|
||||
If you are using a different file backend on the server, you can try to exclude a bug in the
|
||||
backend by reverting to the built-in backend.
|
||||
|
||||
Doing effective debugging requires to provide as much as relevant logs as
|
||||
possible. The log output can help you with tracking down problem, and if you
|
||||
report a bug, you're advised to include the output.
|
||||
Log Files
|
||||
---------
|
||||
|
||||
Client Logfile
|
||||
~~~~~~~~~~~~~~
|
||||
Effectively debugging software requires as much relative information as can be
|
||||
obtained. To assist the ownCloud support personnel, please try to provide as
|
||||
many relevant logs as possible. Log output can help with tracking down
|
||||
problems and, if you report a bug, log output can help to resolve an issue more
|
||||
quickly.
|
||||
|
||||
Start the client with ``--logwindow``. That opens a window providing a view
|
||||
on the current log. It provides a Save button to let you save the log to a
|
||||
file.
|
||||
Obtaining the Client Log File
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
You can also open a log window for an already running session, by simply
|
||||
starting the client again with this parameter. Syntax:
|
||||
To obtain the client log file:
|
||||
|
||||
1. Open the ownCloud Desktop Client.
|
||||
|
||||
2. Press F12 on your keyboard.
|
||||
|
||||
The Log Output window opens.
|
||||
|
||||
.. image:: images/log_output_window.png
|
||||
|
||||
3. Click the 'Save' button.
|
||||
|
||||
The Save Log File window opens.
|
||||
|
||||
.. image:: images/save_log_file.png
|
||||
|
||||
4. Migrate to a location on your system where you want to save your log file.
|
||||
|
||||
5. Name the log file and click the 'Save' button.
|
||||
|
||||
The log files is saved in the location specifed.
|
||||
|
||||
Alternatively, you can launch the ownCloud Log Output window using the
|
||||
``--logwindow`` command. After issuing this command, the Log Output window
|
||||
opens to show the current log. You can then follow the same procedures
|
||||
mentioned above to save the log to a file.
|
||||
|
||||
.. note:: You can also open a log window for an already running session, by
|
||||
restarting the client using the following command:
|
||||
|
||||
* Windows: ``C:\Program Files (x86)\ownCloud\owncloud.exe --logwindow``
|
||||
* Mac OS X: ``/Applications/owncloud.app/Contents/MacOS/owncloud --logwindow``
|
||||
* Linux: ``owncloud --logwindow``
|
||||
|
||||
It is also possible to directly log to a directory, which is an useful option
|
||||
in case the problem only happens ocassionally. In that case it is better to
|
||||
create a huge amount of data, as the log window has a limited buffer.
|
||||
Saving Files Directly
|
||||
~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
To write logs to disk, start the client with ``--logfile <file>``, where
|
||||
``<file`` is the file you want to log to, or ``--logdir <dir>``, where ``<dir>``
|
||||
is an existing directory. In case of ``--logdir``, each sync run will create a
|
||||
new file. To limit the amount of data that accumulates over time, there is another
|
||||
useful parameter: ``--logexpire <hours>```. If that is combined with ```--logdir```
|
||||
the client automatically erases log data in that directory that is older than the
|
||||
given expiry period.
|
||||
The ownCloud client enables you to save log files directly to a predefined file
|
||||
or directory. This is a useful option for troubleshooting sporadic issues as
|
||||
it enables you to log large amounts of data and bypasses the limited buffer
|
||||
settings associated with the log window.
|
||||
|
||||
For example, for a long running test where you intend to keep the log data of the
|
||||
last two days, this would be the command line:
|
||||
To save log files to a file or a directory:
|
||||
|
||||
1. To save to a file, start the client using the ``--logfile <file>`` command,
|
||||
where ``<file>`` is the filename to which you want to save the file.
|
||||
|
||||
2. To save to a directory, start the client using the ``--logdir <dir>`` command, where ``<dir>``
|
||||
is an existing directory.
|
||||
|
||||
When using the ``--logdir`` command, each sync run creates a new file. To limit
|
||||
the amount of data that accumulates over time, you can specify the
|
||||
``--logexpire <hours>`` command. When combined with the ``--logdir`` command,
|
||||
the client automatically erases saved log data in the directory that is older
|
||||
than the specified number of hours.
|
||||
|
||||
As an example, to define a test where you keep log data for two days, you can
|
||||
issue the following command:
|
||||
|
||||
```
|
||||
owncloud --logdir /tmp/owncloud_logs --logexpire 48
|
||||
```
|
||||
|
||||
ownCloud server Logfile
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
ownCloud server Log File
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
The ownCloud server maintains an ownCloud specific logfile as well. It can and
|
||||
must be enabled through the ownCloud Administration page. There you can adjust
|
||||
the loglevel. It is advisable to set it to a verbose level like ``Debug`` or
|
||||
``Info``.
|
||||
The ownCloud server also maintains an ownCloud specific log file. This log file
|
||||
must be enabled through the ownCloud Administration page. On that page, you can
|
||||
adjust the log level. We recommend that when setting the log file level that
|
||||
you set it to a verbose level like ``Debug`` or ``Info``.
|
||||
|
||||
The logfile can be viewed either in the web interface or can be found in the
|
||||
filesystem in the ownCloud server data dir.
|
||||
You can view the server log file using the web interface or you can open it
|
||||
directly from the file system in the ownCloud server data directory.
|
||||
|
||||
Webserver Logfiles
|
||||
~~~~~~~~~~~~~~~~~~
|
||||
.. todo:: Need more information on this. How is the log file accessed?
|
||||
Need to explore procedural steps in access and in saving this file ... similar
|
||||
to how the log file is managed for the client. Perhaps it is detailed in the
|
||||
Admin Guide and a link should be provided from here. I will look into that
|
||||
when I begin heavily editing the Admin Guide.
|
||||
|
||||
Also, please take a look at your webservers error log file to check if there
|
||||
are problems. For Apache on Linux, the error logs usually can be found at
|
||||
``/var/log/apache2``. A file called ``error_log`` shows errors like PHP code
|
||||
problems. A file called ``access_log`` usually records all requests handled
|
||||
by the server. Especially the access_log is a very good debugging tool as the
|
||||
log line contains a lot of information of every request and it's result.
|
||||
Webserver Log Files
|
||||
~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
It can be helpful to view your webservers error log file to isolate any
|
||||
ownCloud-related problems. For Apache on Linux, the error logs are typically
|
||||
located in the ``/var/log/apache2`` directory. Some helpful files include the
|
||||
following:
|
||||
|
||||
- ``error_log`` -- Maintains errors associated with PHP code.
|
||||
- ``access_log`` -- Typically records all requests handled by the server; very
|
||||
useful as a debugging tool because the log line contains information specific
|
||||
to each request and its result.
|
||||
|
||||
More information about the apache logging can be found at
|
||||
You can find more information about Apache logging at
|
||||
``http://httpd.apache.org/docs/current/logs.html``.
|
||||
|
||||
Core Dumps
|
||||
----------
|
||||
|
||||
In case of crashes of the client software, having a core dump helps to
|
||||
debug the issue tremendously.
|
||||
On MAC OS X and Linux systems, and in the unlikely event the client software
|
||||
crashes, the client is able to write a core dump file. Obtaining a core dump
|
||||
file can assist ownCloud Customer Support tremendously in the debugging
|
||||
process.
|
||||
|
||||
The client is able to write a core dump in case of crashing on Linux and
|
||||
MacOSX. To enable that, the environment variable ``OWNCLOUD_CORE_DUMP`` has
|
||||
to be defined.
|
||||
To enable the writing of core dump files, you must define the
|
||||
``OWNCLOUD_CORE_DUMP`` environment variable on the system.
|
||||
|
||||
For example
|
||||
For example:
|
||||
|
||||
```
|
||||
OWNCLOUD_CORE_DUMP=1 owncloud
|
||||
```
|
||||
|
||||
starts the client with core dumping enabled. Core dumps appear in the
|
||||
current working directory, and since they can be fairly large, it is
|
||||
important to have plenty of disk space when running with dumps enabled.
|
||||
This command starts the client with core dumping enabled and saves the files in
|
||||
the current working directory.
|
||||
|
||||
If a core dump file should be transfered back to the developers it
|
||||
should be compressed properly before.
|
||||
.. note:: Core dump files can be fairly large. Before enabling core dumps on
|
||||
your system, ensure that you have enough disk space to accommodate these files.
|
||||
Also, due to their size, we strongly recommend that you properly compress any
|
||||
core dump files prior to sending them to ownCloud Customer Support.
|
||||
|
|
1
shell_integration/CMakeLists.txt
Normal file
|
@ -0,0 +1 @@
|
|||
add_subdirectory(testclient)
|
11
shell_integration/testclient/CMakeLists.txt
Normal file
|
@ -0,0 +1,11 @@
|
|||
cmake_minimum_required(VERSION 2.6)
|
||||
project(socketapiclient)
|
||||
set(socketapiclient_SOURCES main.cpp window.cpp)
|
||||
set(socketapiclient_HEADERS window.h)
|
||||
qt_wrap_ui(socketapiclient_UI_SRCS window.ui)
|
||||
add_executable(socketapiclient ${socketapiclient_SOURCES} ${socketapiclient_HEADERS} ${socketapiclient_UI_SRCS})
|
||||
target_link_libraries(socketapiclient ${QT_LIBRARIES})
|
||||
set_target_properties(socketapiclient PROPERTIES AUTOMOC TRUE)
|
||||
qt5_use_modules(socketapiclient Widgets Network)
|
||||
include_directories(${CMAKE_CURRENT_BINARY_DIR})
|
||||
set_target_properties(socketapiclient PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
|
27
shell_integration/testclient/main.cpp
Normal file
|
@ -0,0 +1,27 @@
|
|||
#include <QApplication>
|
||||
#include <QLocalSocket>
|
||||
#include <QDir>
|
||||
|
||||
#include "window.h"
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QApplication app(argc, argv);
|
||||
QLocalSocket sock;
|
||||
QString sockAddr;
|
||||
#ifdef Q_OS_UNIX
|
||||
sockAddr = QDir::homePath() + QLatin1String("/.local/share/data/ownCloud/socket");
|
||||
#else
|
||||
sockAddr = QLatin1String("\\\\.\\pipe\\ownCloud");
|
||||
#endif
|
||||
Window win(&sock);
|
||||
QObject::connect(&sock, SIGNAL(readyRead()), &win, SLOT(receive()));
|
||||
QObject::connect(&sock, SIGNAL(error(QLocalSocket::LocalSocketError)),
|
||||
&win, SLOT(receiveError(QLocalSocket::LocalSocketError)));
|
||||
|
||||
win.show();
|
||||
sock.connectToServer(sockAddr, QIODevice::ReadWrite);
|
||||
qDebug() << "Connecting to" << sockAddr;
|
||||
|
||||
return app.exec();
|
||||
}
|
22
shell_integration/testclient/socketclient.cpp
Normal file
|
@ -0,0 +1,22 @@
|
|||
|
||||
#include "socketclient.h"
|
||||
|
||||
SocketClient::SocketClient(QObject *parent) :
|
||||
QObject(parent)
|
||||
, sock(new QLocalSocket(this))
|
||||
{
|
||||
QString sockAddr;
|
||||
#ifdef Q_OS_UNIX
|
||||
sockAddr = QDir::homePath() + QLatin1String("/.local/share/data/ownCloud/");
|
||||
#else
|
||||
sockAddr = QLatin1String("\\\\.\\pipe\\ownCloud");
|
||||
#endif
|
||||
sock->connectToServer(sockAddr);
|
||||
sock->open(QIODevice::ReadWrite);
|
||||
connect(sock, SIGNAL(readyRead()), SLOT(writeData()));
|
||||
}
|
||||
|
||||
void SocketClient::writeData()
|
||||
{
|
||||
qDebug() << sock->readAll();
|
||||
}
|
21
shell_integration/testclient/socketclient.h
Normal file
|
@ -0,0 +1,21 @@
|
|||
#ifndef SOCKETCLIENT_H
|
||||
#define SOCKETCLIENT_H
|
||||
|
||||
#include <QObject>
|
||||
|
||||
class QLocalSocket;
|
||||
|
||||
class SocketClient : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit SocketClient(QObject *parent = 0);
|
||||
|
||||
public slots:
|
||||
void writeData();
|
||||
|
||||
private:
|
||||
QLocalSocket *sock;
|
||||
};
|
||||
|
||||
#endif // SOCKETCLIENT_H
|
101
shell_integration/testclient/window.cpp
Normal file
|
@ -0,0 +1,101 @@
|
|||
#include "window.h"
|
||||
#include "ui_window.h"
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QSyntaxHighlighter>
|
||||
|
||||
class LogWindowHighlighter : public QSyntaxHighlighter
|
||||
{
|
||||
public:
|
||||
LogWindowHighlighter(QTextDocument *parent = 0);
|
||||
|
||||
protected:
|
||||
void highlightBlock(const QString &text);
|
||||
void highlightHelper(const QString& text, const QTextCharFormat &format, const QString &exp);
|
||||
};
|
||||
|
||||
Window::Window(QIODevice *dev, QWidget *parent) :
|
||||
QWidget(parent),
|
||||
ui(new Ui::Window)
|
||||
, device(dev)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
connect(ui->inputEdit->lineEdit(), SIGNAL(returnPressed()), SLOT(handleReturn()));
|
||||
addDefaultItems();
|
||||
QFont f("Courier");
|
||||
f.setStyleHint(QFont::Monospace);
|
||||
ui->outputs->setFont(f);
|
||||
new LogWindowHighlighter(ui->outputs->document());
|
||||
}
|
||||
|
||||
Window::~Window()
|
||||
{
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void Window::receive()
|
||||
{
|
||||
QByteArray ba = device->readAll();
|
||||
ui->outputs->insertPlainText(QString::fromLatin1(ba));
|
||||
}
|
||||
|
||||
void Window::receiveError(QLocalSocket::LocalSocketError error)
|
||||
{
|
||||
qDebug() << "Error connecting to socket:" << error;
|
||||
}
|
||||
|
||||
void Window::handleReturn()
|
||||
{
|
||||
QString cmd = ui->inputEdit->currentText()+QLatin1Char('\n');
|
||||
ui->outputs->insertPlainText(cmd);
|
||||
device->write(cmd.toLatin1());
|
||||
ui->inputEdit->lineEdit()->clear();
|
||||
}
|
||||
|
||||
void Window::addDefaultItems()
|
||||
{
|
||||
QStringList commands;
|
||||
commands << "RETRIEVE_FOLDER_STATUS:" << "RETRIEVE_FILE_STATUS:";
|
||||
ui->inputEdit->addItems(commands);
|
||||
}
|
||||
|
||||
|
||||
LogWindowHighlighter::LogWindowHighlighter(QTextDocument *parent)
|
||||
: QSyntaxHighlighter(parent)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void LogWindowHighlighter::highlightBlock(const QString &text)
|
||||
{
|
||||
QTextCharFormat responseKeywordFormat;
|
||||
responseKeywordFormat.setFontWeight(QFont::Bold);
|
||||
responseKeywordFormat.setForeground(Qt::darkMagenta);
|
||||
QString responsePattern = "(UPDATE_VIEW|BROADCAST:|STATUS:)";
|
||||
highlightHelper(text, responseKeywordFormat, responsePattern);
|
||||
|
||||
QTextCharFormat messageKeywordFormat;
|
||||
messageKeywordFormat.setFontWeight(QFont::Bold);
|
||||
messageKeywordFormat.setForeground(Qt::darkYellow);
|
||||
QString messagePattern = "(RETRIEVE_(FOLDER|FILE)_STATUS):";
|
||||
highlightHelper(text, messageKeywordFormat, messagePattern);
|
||||
}
|
||||
|
||||
void LogWindowHighlighter::highlightHelper(const QString& text, const QTextCharFormat &format,
|
||||
const QString &pattern)
|
||||
{
|
||||
QRegExp rex(pattern);
|
||||
int index = text.indexOf(rex);
|
||||
if (index >= 0) {
|
||||
int len = rex.matchedLength();
|
||||
setFormat(index, len, format);
|
||||
int lastMatchedEnd=index+len;
|
||||
int secondDoubleDotIndex = text.indexOf(':', lastMatchedEnd);
|
||||
if (secondDoubleDotIndex >= 0) {
|
||||
QTextCharFormat boldFormat;
|
||||
boldFormat.setFontWeight(QFont::Bold);
|
||||
setFormat(lastMatchedEnd, secondDoubleDotIndex-lastMatchedEnd, boldFormat);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
32
shell_integration/testclient/window.h
Normal file
|
@ -0,0 +1,32 @@
|
|||
#ifndef WINDOW_H
|
||||
#define WINDOW_H
|
||||
|
||||
#include <QWidget>
|
||||
#include <QLocalSocket>
|
||||
|
||||
namespace Ui {
|
||||
class Window;
|
||||
}
|
||||
|
||||
class Window : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit Window(QIODevice *dev, QWidget *parent = 0);
|
||||
~Window();
|
||||
|
||||
public slots:
|
||||
void receive();
|
||||
void receiveError(QLocalSocket::LocalSocketError);
|
||||
|
||||
private slots:
|
||||
void handleReturn();
|
||||
|
||||
private:
|
||||
void addDefaultItems();
|
||||
Ui::Window *ui;
|
||||
QIODevice *device;
|
||||
};
|
||||
|
||||
#endif // WINDOW_H
|
31
shell_integration/testclient/window.ui
Normal file
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>Window</class>
|
||||
<widget class="QWidget" name="Window">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>400</width>
|
||||
<height>300</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>SocketAPI Test Client</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QComboBox" name="inputEdit">
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPlainTextEdit" name="outputs"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
|
@ -64,8 +64,8 @@ public:
|
|||
*/
|
||||
const QColor & color() const { return m_color; }
|
||||
|
||||
virtual QSize sizeHint() const;
|
||||
int heightForWidth(int w) const;
|
||||
virtual QSize sizeHint() const Q_DECL_OVERRIDE;
|
||||
int heightForWidth(int w) const Q_DECL_OVERRIDE;
|
||||
public slots:
|
||||
/*! Starts the spin animation.
|
||||
\sa stopAnimation isAnimated
|
||||
|
@ -95,8 +95,8 @@ public slots:
|
|||
*/
|
||||
void setColor(const QColor & color);
|
||||
protected:
|
||||
virtual void timerEvent(QTimerEvent * event);
|
||||
virtual void paintEvent(QPaintEvent * event);
|
||||
virtual void timerEvent(QTimerEvent * event) Q_DECL_OVERRIDE;
|
||||
virtual void paintEvent(QPaintEvent * event) Q_DECL_OVERRIDE;
|
||||
private:
|
||||
int m_angle;
|
||||
int m_timerId;
|
||||
|
|
4
src/3rdparty/fancylineedit/fancylineedit.cpp
vendored
|
@ -99,7 +99,7 @@ class FancyLineEditPrivate : public QObject
|
|||
public:
|
||||
explicit FancyLineEditPrivate(FancyLineEdit *parent);
|
||||
|
||||
virtual bool eventFilter(QObject *obj, QEvent *event);
|
||||
virtual bool eventFilter(QObject *obj, QEvent *event) Q_DECL_OVERRIDE;
|
||||
|
||||
FancyLineEdit *m_lineEdit;
|
||||
QPixmap m_pixmap[2];
|
||||
|
@ -317,7 +317,7 @@ void FancyLineEdit::setButtonFocusPolicy(Side side, Qt::FocusPolicy policy)
|
|||
// IconButton - helper class to represent a clickable icon
|
||||
|
||||
IconButton::IconButton(QWidget *parent)
|
||||
: QAbstractButton(parent), m_autoHide(false)
|
||||
: QAbstractButton(parent), m_iconOpacity(0), m_autoHide(false)
|
||||
{
|
||||
setCursor(Qt::ArrowCursor);
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
|
4
src/3rdparty/fancylineedit/fancylineedit.h
vendored
|
@ -45,7 +45,7 @@ class IconButton: public QAbstractButton
|
|||
Q_PROPERTY(QPixmap pixmap READ pixmap WRITE setPixmap)
|
||||
public:
|
||||
explicit IconButton(QWidget *parent = 0);
|
||||
void paintEvent(QPaintEvent *event);
|
||||
void paintEvent(QPaintEvent *event) Q_DECL_OVERRIDE;
|
||||
void setPixmap(const QPixmap &pixmap) { m_pixmap = pixmap; update(); }
|
||||
QPixmap pixmap() const { return m_pixmap; }
|
||||
float iconOpacity() { return m_iconOpacity; }
|
||||
|
@ -105,7 +105,7 @@ private slots:
|
|||
void iconClicked();
|
||||
|
||||
protected:
|
||||
virtual void resizeEvent(QResizeEvent *e);
|
||||
virtual void resizeEvent(QResizeEvent *e) Q_DECL_OVERRIDE;
|
||||
|
||||
private:
|
||||
void updateMargins();
|
||||
|
|
|
@ -50,7 +50,7 @@ public:
|
|||
|
||||
void setActivationWindow(QWidget* aw, bool activateOnMessage = true);
|
||||
QWidget* activationWindow() const;
|
||||
bool event(QEvent *event);
|
||||
bool event(QEvent *event) Q_DECL_OVERRIDE;
|
||||
|
||||
QString applicationId() const;
|
||||
void setBlock(bool value);
|
||||
|
|
|
@ -48,21 +48,6 @@ if (APPLE)
|
|||
)
|
||||
endif()
|
||||
|
||||
set(3rdparty_HEADER
|
||||
3rdparty/qtsingleapplication/qtlocalpeer.h
|
||||
3rdparty/qtsingleapplication/qtsingleapplication.h
|
||||
3rdparty/qtsingleapplication/qtsinglecoreapplication.h
|
||||
3rdparty/fancylineedit/fancylineedit.h
|
||||
3rdparty/QProgressIndicator/QProgressIndicator.h
|
||||
)
|
||||
|
||||
if (APPLE)
|
||||
list(APPEND 3rdparty_HEADER
|
||||
3rdparty/qtmacgoodies/src/macpreferenceswindow.h
|
||||
3rdparty/qtmacgoodies/src/macstandardicon.h
|
||||
)
|
||||
endif()
|
||||
|
||||
if(NOT WIN32)
|
||||
list(APPEND 3rdparty_SRC 3rdparty/qtlockedfile/qtlockedfile_unix.cpp)
|
||||
else()
|
||||
|
@ -79,9 +64,6 @@ set(3rdparty_INC
|
|||
)
|
||||
|
||||
set(libsync_SRCS
|
||||
mirall/folderman.cpp
|
||||
mirall/folder.cpp
|
||||
mirall/folderwatcher.cpp
|
||||
mirall/syncresult.cpp
|
||||
mirall/mirallconfigfile.cpp
|
||||
mirall/syncengine.cpp
|
||||
|
@ -103,8 +85,8 @@ set(libsync_SRCS
|
|||
mirall/account.cpp
|
||||
mirall/quotainfo.cpp
|
||||
mirall/clientproxy.cpp
|
||||
mirall/syncrunfilelog.cpp
|
||||
mirall/cookiejar.cpp
|
||||
mirall/syncfilestatus.cpp
|
||||
creds/dummycredentials.cpp
|
||||
creds/abstractcredentials.cpp
|
||||
creds/credentialsfactory.cpp
|
||||
|
@ -129,24 +111,10 @@ else()
|
|||
)
|
||||
endif()
|
||||
|
||||
IF( NOT WIN32 AND NOT APPLE )
|
||||
set(libsync_SRCS ${libsync_SRCS} mirall/folderwatcher_linux.cpp)
|
||||
ENDIF()
|
||||
IF( WIN32 )
|
||||
set(libsync_SRCS ${libsync_SRCS} mirall/folderwatcher_win.cpp)
|
||||
ENDIF()
|
||||
IF( APPLE )
|
||||
list(APPEND libsync_SRCS mirall/folderwatcher_mac.cpp)
|
||||
ENDIF()
|
||||
|
||||
|
||||
# These headers are installed for libowncloudsync to be used by 3rd party apps
|
||||
set(owncloudsync_HEADERS
|
||||
mirall/account.h
|
||||
mirall/syncengine.h
|
||||
mirall/folder.h
|
||||
mirall/folderman.h
|
||||
mirall/folderwatcher.h
|
||||
mirall/mirallconfigfile.h
|
||||
mirall/networkjobs.h
|
||||
mirall/progressdispatcher.h
|
||||
|
@ -272,9 +240,13 @@ qt_wrap_ui(mirall_UI_SRCS ${mirall_UI})
|
|||
set(mirall_SRCS
|
||||
mirall/application.cpp
|
||||
mirall/systray.cpp
|
||||
mirall/folderman.cpp
|
||||
mirall/folder.cpp
|
||||
mirall/folderwatcher.cpp
|
||||
mirall/folderwizard.cpp
|
||||
mirall/folderstatusmodel.cpp
|
||||
mirall/protocolwidget.cpp
|
||||
mirall/openfilemanager.cpp
|
||||
wizard/owncloudwizard.cpp
|
||||
wizard/owncloudsetuppage.cpp
|
||||
wizard/owncloudhttpcredspage.cpp
|
||||
|
@ -294,63 +266,38 @@ set(mirall_SRCS
|
|||
mirall/owncloudgui.cpp
|
||||
mirall/socketapi.cpp
|
||||
mirall/sslbutton.cpp
|
||||
mirall/syncrunfilelog.cpp
|
||||
)
|
||||
|
||||
|
||||
|
||||
set(mirall_HEADERS
|
||||
mirall/application.h
|
||||
mirall/systray.h
|
||||
mirall/folderwizard.h
|
||||
mirall/owncloudsetupwizard.h
|
||||
wizard/owncloudwizard.h
|
||||
wizard/owncloudsetuppage.h
|
||||
wizard/owncloudhttpcredspage.h
|
||||
wizard/abstractcredswizardpage.h
|
||||
wizard/owncloudwizardresultpage.h
|
||||
wizard/owncloudwizardcommon.h
|
||||
wizard/owncloudshibbolethcredspage.h
|
||||
wizard/owncloudadvancedsetuppage.h
|
||||
mirall/folderstatusmodel.h
|
||||
mirall/sslerrordialog.h
|
||||
mirall/logbrowser.h
|
||||
mirall/settingsdialog.h
|
||||
mirall/generalsettings.h
|
||||
mirall/networksettings.h
|
||||
mirall/accountsettings.h
|
||||
mirall/ignorelisteditor.h
|
||||
mirall/protocolwidget.h
|
||||
mirall/owncloudgui.h
|
||||
mirall/socketapi.h
|
||||
mirall/sslbutton.h
|
||||
)
|
||||
|
||||
set(updater_SRCS
|
||||
updater/updateinfo.cpp
|
||||
updater/updater.cpp
|
||||
updater/ocupdater.cpp
|
||||
)
|
||||
|
||||
set(updater_HEADERS
|
||||
updater/updater.h
|
||||
updater/ocupdater.h
|
||||
)
|
||||
|
||||
IF( APPLE )
|
||||
list(APPEND mirall_SRCS mirall/cocoainitializer_mac.mm)
|
||||
list(APPEND mirall_HEADERS mirall/cocoainitializer.h)
|
||||
|
||||
list(APPEND mirall_SRCS mirall/settingsdialogmac.cpp)
|
||||
list(APPEND mirall_HEADERS mirall/settingsdialogmac.h)
|
||||
|
||||
if(SPARKLE_FOUND)
|
||||
# Define this, we need to check in updater.cpp
|
||||
add_definitions( -DHAVE_SPARKLE )
|
||||
list(APPEND updater_SRCS updater/sparkleupdater_mac.mm)
|
||||
list(APPEND updater_HEADERS updater/sparkleupdater.h)
|
||||
endif()
|
||||
ENDIF()
|
||||
|
||||
IF( NOT WIN32 AND NOT APPLE )
|
||||
set(mirall_SRCS ${mirall_SRCS} mirall/folderwatcher_linux.cpp)
|
||||
ENDIF()
|
||||
IF( WIN32 )
|
||||
set(mirall_SRCS ${mirall_SRCS} mirall/folderwatcher_win.cpp)
|
||||
ENDIF()
|
||||
IF( APPLE )
|
||||
list(APPEND mirall_SRCS mirall/folderwatcher_mac.cpp)
|
||||
ENDIF()
|
||||
|
||||
# csync is required.
|
||||
include_directories(../csync/src ../csync/src/httpbf/src ${CMAKE_CURRENT_BINARY_DIR}/../csync ${CMAKE_CURRENT_BINARY_DIR}/../csync/src )
|
||||
include_directories(${3rdparty_INC})
|
||||
|
@ -358,12 +305,10 @@ include_directories(${3rdparty_INC})
|
|||
qt_add_translation(mirall_I18N ${TRANSLATIONS})
|
||||
|
||||
set( final_src
|
||||
${mirall_HEADERS}
|
||||
${MIRALL_RC_SRC}
|
||||
${mirall_SRCS}
|
||||
${mirall_UI_SRCS}
|
||||
${mirallMoc}
|
||||
${mirall_HEADERS}
|
||||
${mirall_I18N}
|
||||
${3rdparty_SRC}
|
||||
${3rdparty_MOC}
|
||||
|
|
|
@ -27,17 +27,17 @@ public:
|
|||
|
||||
QString _user;
|
||||
QString _password;
|
||||
void syncContextPreInit(CSYNC* ctx);
|
||||
void syncContextPreStart(CSYNC* ctx);
|
||||
bool changed(AbstractCredentials* credentials) const;
|
||||
QString authType() const;
|
||||
QString user() const;
|
||||
QNetworkAccessManager* getQNAM() const;
|
||||
bool ready() const;
|
||||
bool stillValid(QNetworkReply *reply);
|
||||
void fetch(Account*);
|
||||
void persist(Account*);
|
||||
void invalidateToken(Account *) {}
|
||||
void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
|
||||
QString authType() const Q_DECL_OVERRIDE;
|
||||
QString user() const Q_DECL_OVERRIDE;
|
||||
QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
|
||||
bool ready() const Q_DECL_OVERRIDE;
|
||||
bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
|
||||
void fetch(Account*) Q_DECL_OVERRIDE;
|
||||
void persist(Account*) Q_DECL_OVERRIDE;
|
||||
void invalidateToken(Account *) Q_DECL_OVERRIDE {}
|
||||
};
|
||||
|
||||
} // ns Mirall
|
||||
|
|
|
@ -48,8 +48,9 @@ int getauth(const char *prompt,
|
|||
void *userdata)
|
||||
{
|
||||
int re = 0;
|
||||
QMutex mutex;
|
||||
// ### safe?
|
||||
|
||||
// ### safe? Not really. If the wizard is run in the main thread, the caccount could change during the sync.
|
||||
// Ideally, http_credentials could be use userdata, but userdata is the SyncEngine.
|
||||
HttpCredentials* http_credentials = qobject_cast<HttpCredentials*>(AccountManager::instance()->account()->credentials());
|
||||
|
||||
if (!http_credentials) {
|
||||
|
@ -63,10 +64,8 @@ int getauth(const char *prompt,
|
|||
|
||||
if( qPrompt == QLatin1String("Enter your username:") ) {
|
||||
// qDebug() << "OOO Username requested!";
|
||||
QMutexLocker locker( &mutex );
|
||||
qstrncpy( buf, user.toUtf8().constData(), len );
|
||||
} else if( qPrompt == QLatin1String("Enter your password:") ) {
|
||||
QMutexLocker locker( &mutex );
|
||||
// qDebug() << "OOO Password requested!";
|
||||
qstrncpy( buf, pwd.toUtf8().constData(), len );
|
||||
} else {
|
||||
|
@ -86,7 +85,7 @@ public:
|
|||
HttpCredentialsAccessManager(const HttpCredentials *cred, QObject* parent = 0)
|
||||
: MirallAccessManager(parent), _cred(cred) {}
|
||||
protected:
|
||||
QNetworkReply *createRequest(Operation op, const QNetworkRequest &request, QIODevice *outgoingData) {
|
||||
QNetworkReply *createRequest(Operation op, const QNetworkRequest &request, QIODevice *outgoingData) Q_DECL_OVERRIDE {
|
||||
QByteArray credHash = QByteArray(_cred->user().toUtf8()+":"+_cred->password().toUtf8()).toBase64();
|
||||
QNetworkRequest req(request);
|
||||
req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash);
|
||||
|
@ -101,7 +100,8 @@ HttpCredentials::HttpCredentials()
|
|||
: _user(),
|
||||
_password(),
|
||||
_ready(false),
|
||||
_fetchJobInProgress(false)
|
||||
_fetchJobInProgress(false),
|
||||
_readPwdFromDeprecatedPlace(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -230,6 +230,7 @@ void HttpCredentials::fetch(Account *account)
|
|||
job->setProperty("account", QVariant::fromValue(account));
|
||||
job->start();
|
||||
_fetchJobInProgress = true;
|
||||
_readPwdFromDeprecatedPlace = true;
|
||||
}
|
||||
}
|
||||
bool HttpCredentials::stillValid(QNetworkReply *reply)
|
||||
|
@ -261,18 +262,40 @@ void HttpCredentials::slotReadJobDone(QKeychain::Job *job)
|
|||
_ready = true;
|
||||
emit fetched();
|
||||
} else {
|
||||
if( error != NoError ) {
|
||||
qDebug() << "Error while reading password" << job->errorString();
|
||||
// we come here if the password is empty or any other keychain
|
||||
// error happend.
|
||||
// In all error conditions it should
|
||||
// ask the user for the password interactively now.
|
||||
if( _readPwdFromDeprecatedPlace ) {
|
||||
// there simply was not a password. Lets restart a read job without
|
||||
// a settings object as we did it in older client releases.
|
||||
ReadPasswordJob *job = new ReadPasswordJob(Theme::instance()->appName());
|
||||
|
||||
const QString kck = keychainKey(account->url().toString(), _user);
|
||||
job->setKey(kck);
|
||||
|
||||
connect(job, SIGNAL(finished(QKeychain::Job*)), SLOT(slotReadJobDone(QKeychain::Job*)));
|
||||
job->setProperty("account", QVariant::fromValue(account));
|
||||
job->start();
|
||||
_readPwdFromDeprecatedPlace = false; // do try that only once.
|
||||
_fetchJobInProgress = true;
|
||||
// Note: if this read job succeeds, the value from the old place is still
|
||||
// NOT persisted into the new account.
|
||||
} else {
|
||||
// interactive password dialog starts here
|
||||
bool ok;
|
||||
QString pwd = queryPassword(&ok);
|
||||
_fetchJobInProgress = false;
|
||||
if (ok) {
|
||||
_password = pwd;
|
||||
_ready = true;
|
||||
persist(account);
|
||||
} else {
|
||||
_password = QString::null;
|
||||
_ready = false;
|
||||
}
|
||||
emit fetched();
|
||||
}
|
||||
bool ok;
|
||||
QString pwd = queryPassword(&ok);
|
||||
_fetchJobInProgress = false;
|
||||
if (ok) {
|
||||
_password = pwd;
|
||||
_ready = true;
|
||||
persist(account);
|
||||
}
|
||||
emit fetched();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -38,19 +38,19 @@ public:
|
|||
HttpCredentials();
|
||||
HttpCredentials(const QString& user, const QString& password);
|
||||
|
||||
void syncContextPreInit(CSYNC* ctx);
|
||||
void syncContextPreStart(CSYNC* ctx);
|
||||
bool changed(AbstractCredentials* credentials) const;
|
||||
QString authType() const;
|
||||
QNetworkAccessManager* getQNAM() const;
|
||||
bool ready() const;
|
||||
void fetch(Account *account);
|
||||
bool stillValid(QNetworkReply *reply);
|
||||
void persist(Account *account);
|
||||
QString user() const;
|
||||
void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
|
||||
QString authType() const Q_DECL_OVERRIDE;
|
||||
QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
|
||||
bool ready() const Q_DECL_OVERRIDE;
|
||||
void fetch(Account *account) Q_DECL_OVERRIDE;
|
||||
bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
|
||||
void persist(Account *account) Q_DECL_OVERRIDE;
|
||||
QString user() const Q_DECL_OVERRIDE;
|
||||
QString password() const;
|
||||
QString queryPassword(bool *ok);
|
||||
void invalidateToken(Account *account);
|
||||
void invalidateToken(Account *account) Q_DECL_OVERRIDE;
|
||||
QString fetchUser(Account *account);
|
||||
|
||||
private Q_SLOTS:
|
||||
|
@ -63,6 +63,7 @@ private:
|
|||
QString _password;
|
||||
bool _ready;
|
||||
bool _fetchJobInProgress; //True if the keychain job is in progress or the input dialog visible
|
||||
bool _readPwdFromDeprecatedPlace;
|
||||
};
|
||||
|
||||
} // ns Mirall
|
||||
|
|
|
@ -26,17 +26,15 @@ class ShibbolethUserJob : public AbstractNetworkJob {
|
|||
Q_OBJECT
|
||||
public:
|
||||
explicit ShibbolethUserJob(Account *account, QObject* parent = 0);
|
||||
void start();
|
||||
public slots:
|
||||
void start() Q_DECL_OVERRIDE;
|
||||
|
||||
signals:
|
||||
// is always emitted when the job is finished. user is empty in case of error.
|
||||
void userFetched(const QString &user);
|
||||
|
||||
// Another job need to be created
|
||||
void tryAgain();
|
||||
|
||||
private slots:
|
||||
virtual bool finished();
|
||||
virtual bool finished() Q_DECL_OVERRIDE;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -18,10 +18,8 @@
|
|||
#include <QWebFrame>
|
||||
#include <QWebPage>
|
||||
#include <QMessageBox>
|
||||
#include <QAuthenticator>
|
||||
#include <QNetworkReply>
|
||||
|
||||
#include "creds/shibboleth/authenticationdialog.h"
|
||||
#include "creds/shibboleth/shibbolethwebview.h"
|
||||
#include "creds/shibbolethcredentials.h"
|
||||
#include "mirall/account.h"
|
||||
|
@ -36,6 +34,7 @@ ShibbolethWebView::ShibbolethWebView(Account* account, QWidget* parent)
|
|||
: QWebView(parent)
|
||||
, _account(account)
|
||||
, _accepted(false)
|
||||
, _cursorOverriden(false)
|
||||
{
|
||||
// no minimize
|
||||
setWindowFlags(Qt::Dialog);
|
||||
|
@ -81,6 +80,10 @@ void ShibbolethWebView::onNewCookiesForUrl (const QList<QNetworkCookie>& cookieL
|
|||
|
||||
void ShibbolethWebView::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
if (_cursorOverriden) {
|
||||
QApplication::restoreOverrideCursor();
|
||||
}
|
||||
|
||||
if (!_accepted) {
|
||||
Q_EMIT rejected();
|
||||
}
|
||||
|
@ -89,12 +92,17 @@ void ShibbolethWebView::closeEvent(QCloseEvent *event)
|
|||
|
||||
void ShibbolethWebView::slotLoadStarted()
|
||||
{
|
||||
QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
|
||||
if (!_cursorOverriden) {
|
||||
QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
|
||||
_cursorOverriden = true;
|
||||
}
|
||||
}
|
||||
|
||||
void ShibbolethWebView::slotLoadFinished(bool success)
|
||||
{
|
||||
QApplication::restoreOverrideCursor();
|
||||
if (_cursorOverriden) {
|
||||
QApplication::restoreOverrideCursor();
|
||||
}
|
||||
|
||||
if (!title().isNull()) {
|
||||
setWindowTitle(tr("%1 - %2").arg(Theme::instance()->appNameGUI(), title()));
|
||||
|
@ -106,23 +114,6 @@ void ShibbolethWebView::slotLoadFinished(bool success)
|
|||
}
|
||||
}
|
||||
|
||||
void ShibbolethWebView::slotHandleAuthentication(QNetworkReply *reply, QAuthenticator *authenticator)
|
||||
{
|
||||
Q_UNUSED(reply)
|
||||
QUrl url = reply->url();
|
||||
// show only scheme, host and port
|
||||
QUrl reducedUrl;
|
||||
reducedUrl.setScheme(url.scheme());
|
||||
reducedUrl.setHost(url.host());
|
||||
reducedUrl.setPort(url.port());
|
||||
|
||||
AuthenticationDialog dialog(authenticator->realm(), reducedUrl.toString(), this);
|
||||
if (dialog.exec() == QDialog::Accepted) {
|
||||
authenticator->setUser(dialog.user());
|
||||
authenticator->setPassword(dialog.password());
|
||||
}
|
||||
}
|
||||
|
||||
void ShibbolethWebView::accept()
|
||||
{
|
||||
_accepted = true;
|
||||
|
|
|
@ -37,7 +37,7 @@ public:
|
|||
ShibbolethWebView(Account *account, ShibbolethCookieJar* jar, QWidget* parent = 0);
|
||||
~ShibbolethWebView();
|
||||
|
||||
void closeEvent(QCloseEvent *event);
|
||||
void closeEvent(QCloseEvent *event) Q_DECL_OVERRIDE;
|
||||
|
||||
Q_SIGNALS:
|
||||
void shibbolethCookieReceived(const QNetworkCookie &cookie, Account *account);
|
||||
|
@ -47,7 +47,6 @@ private Q_SLOTS:
|
|||
void onNewCookiesForUrl(const QList<QNetworkCookie>& cookieList, const QUrl& url);
|
||||
void slotLoadStarted();
|
||||
void slotLoadFinished(bool success);
|
||||
void slotHandleAuthentication(QNetworkReply*,QAuthenticator*);
|
||||
|
||||
protected:
|
||||
void accept();
|
||||
|
@ -56,6 +55,7 @@ private:
|
|||
void setup(Account *account, ShibbolethCookieJar* jar);
|
||||
QPointer<Account> _account;
|
||||
bool _accepted;
|
||||
bool _cursorOverriden;
|
||||
};
|
||||
|
||||
} // ns Mirall
|
||||
|
|
|
@ -16,9 +16,11 @@
|
|||
#include <QSettings>
|
||||
#include <QNetworkReply>
|
||||
#include <QMessageBox>
|
||||
#include <QAuthenticator>
|
||||
#include <QDebug>
|
||||
|
||||
#include "creds/shibbolethcredentials.h"
|
||||
#include "creds/shibboleth/authenticationdialog.h"
|
||||
#include "creds/shibboleth/shibbolethwebview.h"
|
||||
#include "creds/shibboleth/shibbolethrefresher.h"
|
||||
#include "creds/shibbolethcredentials.h"
|
||||
|
@ -92,6 +94,23 @@ ShibbolethCredentials::ShibbolethCredentials()
|
|||
_browser(0)
|
||||
{}
|
||||
|
||||
ShibbolethCredentials::ShibbolethCredentials(const QNetworkCookie& cookie, Account* account)
|
||||
: _ready(true),
|
||||
_stillValid(true),
|
||||
_fetchJobInProgress(false),
|
||||
_browser(0),
|
||||
_shibCookie(cookie)
|
||||
{
|
||||
if (account) {
|
||||
/* The _user has not yet been fetched, so fetch it now */
|
||||
ShibbolethUserJob *job = new ShibbolethUserJob(account, this);
|
||||
connect(job, SIGNAL(userFetched(QString)), this, SLOT(slotUserFetched(QString)));
|
||||
QTimer::singleShot(1234, job, SLOT(start()));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void ShibbolethCredentials::syncContextPreInit(CSYNC* ctx)
|
||||
{
|
||||
csync_set_auth_callback (ctx, handleNeonSSLProblems);
|
||||
|
@ -154,6 +173,8 @@ QNetworkAccessManager* ShibbolethCredentials::getQNAM() const
|
|||
QNetworkAccessManager* qnam(new MirallAccessManager);
|
||||
connect(qnam, SIGNAL(finished(QNetworkReply*)),
|
||||
this, SLOT(slotReplyFinished(QNetworkReply*)));
|
||||
connect(qnam, SIGNAL(authenticationRequired(QNetworkReply*,QAuthenticator*)),
|
||||
SLOT(slotHandleAuthentication(QNetworkReply*,QAuthenticator*)));
|
||||
return qnam;
|
||||
}
|
||||
|
||||
|
@ -298,6 +319,23 @@ void ShibbolethCredentials::invalidateAndFetch(Account* account)
|
|||
job->start();
|
||||
}
|
||||
|
||||
void ShibbolethCredentials::slotHandleAuthentication(QNetworkReply *reply, QAuthenticator *authenticator)
|
||||
{
|
||||
Q_UNUSED(reply)
|
||||
QUrl url = reply->url();
|
||||
// show only scheme, host and port
|
||||
QUrl reducedUrl;
|
||||
reducedUrl.setScheme(url.scheme());
|
||||
reducedUrl.setHost(url.host());
|
||||
reducedUrl.setPort(url.port());
|
||||
|
||||
AuthenticationDialog dialog(authenticator->realm(), reducedUrl.toString());
|
||||
if (dialog.exec() == QDialog::Accepted) {
|
||||
authenticator->setUser(dialog.user());
|
||||
authenticator->setPassword(dialog.password());
|
||||
}
|
||||
}
|
||||
|
||||
void ShibbolethCredentials::slotInvalidateAndFetchInvalidateDone(QKeychain::Job* job)
|
||||
{
|
||||
Account *account = qvariant_cast<Account*>(job->property("account"));
|
||||
|
@ -350,6 +388,13 @@ void ShibbolethCredentials::showLoginWindow(Account* account)
|
|||
// FIXME On OS X this does not raise properly
|
||||
return;
|
||||
}
|
||||
|
||||
CookieJar *jar = static_cast<CookieJar*>(account->networkAccessManager()->cookieJar());
|
||||
// When opening a new window clear all the session cookie that might keep the user from logging in
|
||||
// (or the session may already be open in the server, and there will not be redirect asking for the
|
||||
// real long term cookie we want to store)
|
||||
jar->clearSessionCookies();
|
||||
|
||||
_browser = new ShibbolethWebView(account);
|
||||
connect(_browser, SIGNAL(shibbolethCookieReceived(QNetworkCookie, Account*)),
|
||||
this, SLOT(onShibbolethCookieReceived(QNetworkCookie, Account*)), Qt::QueuedConnection);
|
||||
|
|
|
@ -26,6 +26,8 @@ namespace QKeychain {
|
|||
class Job;
|
||||
}
|
||||
|
||||
class QAuthenticator;
|
||||
|
||||
namespace Mirall
|
||||
{
|
||||
|
||||
|
@ -38,17 +40,20 @@ Q_OBJECT
|
|||
public:
|
||||
ShibbolethCredentials();
|
||||
|
||||
void syncContextPreInit(CSYNC* ctx);
|
||||
void syncContextPreStart(CSYNC* ctx);
|
||||
bool changed(AbstractCredentials* credentials) const;
|
||||
QString authType() const;
|
||||
QString user() const;
|
||||
QNetworkAccessManager* getQNAM() const;
|
||||
bool ready() const;
|
||||
void fetch(Account *account);
|
||||
bool stillValid(QNetworkReply *reply);
|
||||
void persist(Account *account);
|
||||
void invalidateToken(Account *account);
|
||||
/* create a credidentials for an already connected account */
|
||||
ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc);
|
||||
|
||||
void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
void syncContextPreStart(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||
bool changed(AbstractCredentials* credentials) const Q_DECL_OVERRIDE;
|
||||
QString authType() const Q_DECL_OVERRIDE;
|
||||
QString user() const Q_DECL_OVERRIDE;
|
||||
QNetworkAccessManager* getQNAM() const Q_DECL_OVERRIDE;
|
||||
bool ready() const Q_DECL_OVERRIDE;
|
||||
void fetch(Account *account) Q_DECL_OVERRIDE;
|
||||
bool stillValid(QNetworkReply *reply) Q_DECL_OVERRIDE;
|
||||
void persist(Account *account) Q_DECL_OVERRIDE;
|
||||
void invalidateToken(Account *account) Q_DECL_OVERRIDE;
|
||||
|
||||
void showLoginWindow(Account*);
|
||||
|
||||
|
@ -57,7 +62,8 @@ public:
|
|||
static QByteArray shibCookieName();
|
||||
|
||||
public Q_SLOTS:
|
||||
void invalidateAndFetch(Account *account);
|
||||
void invalidateAndFetch(Account *account) Q_DECL_OVERRIDE;
|
||||
void slotHandleAuthentication(QNetworkReply*,QAuthenticator*);
|
||||
|
||||
private Q_SLOTS:
|
||||
void onShibbolethCookieReceived(const QNetworkCookie&, Account*);
|
||||
|
|
|
@ -79,15 +79,16 @@ public:
|
|||
: MirallAccessManager(parent), _cred(cred) {}
|
||||
protected:
|
||||
QNetworkReply *createRequest(Operation op, const QNetworkRequest &request, QIODevice *outgoingData) {
|
||||
QByteArray credHash = QByteArray(_cred->user().toUtf8()+":"+_cred->password().toUtf8()).toBase64();
|
||||
QNetworkRequest req(request);
|
||||
req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash);
|
||||
//qDebug() << "Request for " << req.url() << "with authorization" << QByteArray::fromBase64(credHash);
|
||||
if (_cred->user().isEmpty() || _cred->password().isEmpty() || _cred->_token.isEmpty()) {
|
||||
qWarning() << Q_FUNC_INFO << "Empty user/password/token provided!";
|
||||
}
|
||||
|
||||
// Append token cookie
|
||||
QList<QNetworkCookie> cookies = request.header(QNetworkRequest::CookieHeader).value<QList<QNetworkCookie> >();
|
||||
cookies.append(QNetworkCookie::parseCookies(_cred->_token.toUtf8()));
|
||||
req.setHeader(QNetworkRequest::CookieHeader, QVariant::fromValue(cookies));
|
||||
QNetworkRequest req(request);
|
||||
|
||||
QByteArray credHash = QByteArray(_cred->user().toUtf8()+":"+_cred->password().toUtf8()).toBase64();
|
||||
req.setRawHeader(QByteArray("Authorization"), QByteArray("Basic ") + credHash);
|
||||
|
||||
req.setRawHeader("Cookie", _cred->_token.toUtf8()); // analogous to neon in syncContextPreStart
|
||||
|
||||
return MirallAccessManager::createRequest(op, req, outgoingData);
|
||||
}
|
||||
|
@ -161,12 +162,6 @@ bool TokenCredentials::ready() const
|
|||
return _ready;
|
||||
}
|
||||
|
||||
QString TokenCredentials::fetchUser(Account* account)
|
||||
{
|
||||
_user = account->credentialSetting(QLatin1String(userC)).toString();
|
||||
return _user;
|
||||
}
|
||||
|
||||
void TokenCredentials::fetch(Account *account)
|
||||
{
|
||||
if( !account ) {
|
||||
|
@ -174,10 +169,11 @@ void TokenCredentials::fetch(Account *account)
|
|||
}
|
||||
Q_EMIT fetched();
|
||||
}
|
||||
|
||||
bool TokenCredentials::stillValid(QNetworkReply *reply)
|
||||
{
|
||||
return ((reply->error() != QNetworkReply::AuthenticationRequiredError)
|
||||
// returned if user or password is incorrect
|
||||
// returned if user/password or token are incorrect
|
||||
&& (reply->error() != QNetworkReply::OperationCanceledError
|
||||
|| !reply->property(authenticationFailedC).toBool()));
|
||||
}
|
||||
|
@ -189,19 +185,12 @@ QString TokenCredentials::queryPassword(bool *ok)
|
|||
|
||||
void TokenCredentials::invalidateToken(Account *account)
|
||||
{
|
||||
_password = QString();
|
||||
qDebug() << Q_FUNC_INFO;
|
||||
_ready = false;
|
||||
|
||||
// User must be fetched from config file to generate a valid key
|
||||
fetchUser(account);
|
||||
|
||||
const QString kck = keychainKey(account->url().toString(), _user);
|
||||
if( kck.isEmpty() ) {
|
||||
qDebug() << "InvalidateToken: User is empty, bailing out!";
|
||||
return;
|
||||
}
|
||||
|
||||
account->clearCookieJar();
|
||||
_token = QString();
|
||||
_user = QString();
|
||||
_password = QString();
|
||||
}
|
||||
|
||||
void TokenCredentials::persist(Account *account)
|
||||
|
|
|
@ -53,7 +53,6 @@ public:
|
|||
QString password() const;
|
||||
QString queryPassword(bool *ok);
|
||||
void invalidateToken(Account *account);
|
||||
QString fetchUser(Account *account);
|
||||
|
||||
private Q_SLOTS:
|
||||
void slotAuthentication(QNetworkReply*, QAuthenticator*);
|
||||
|
@ -61,7 +60,7 @@ private Q_SLOTS:
|
|||
private:
|
||||
QString _user;
|
||||
QString _password;
|
||||
QString _token;
|
||||
QString _token; // the cookies
|
||||
bool _ready;
|
||||
};
|
||||
|
||||
|
|
|
@ -416,28 +416,6 @@ void AccountSettings::setFolderList( const Folder::Map &folders )
|
|||
|
||||
}
|
||||
|
||||
// move from Application
|
||||
void AccountSettings::slotFolderOpenAction( const QString& alias )
|
||||
{
|
||||
Folder *f = FolderMan::instance()->folder(alias);
|
||||
qDebug() << "opening local url " << f->path();
|
||||
if( f ) {
|
||||
QUrl url(f->path(), QUrl::TolerantMode);
|
||||
url.setScheme( QLatin1String("file") );
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
// work around a bug in QDesktopServices on Win32, see i-net
|
||||
QString filePath = f->path();
|
||||
|
||||
if (filePath.startsWith(QLatin1String("\\\\")) || filePath.startsWith(QLatin1String("//")))
|
||||
url.setUrl(QDir::toNativeSeparators(filePath));
|
||||
else
|
||||
url = QUrl::fromLocalFile(filePath);
|
||||
#endif
|
||||
QDesktopServices::openUrl(url);
|
||||
}
|
||||
}
|
||||
|
||||
void AccountSettings::slotEnableCurrentFolder()
|
||||
{
|
||||
QModelIndex selected = ui->_folderList->selectionModel()->currentIndex();
|
||||
|
@ -454,7 +432,11 @@ void AccountSettings::slotEnableCurrentFolder()
|
|||
|
||||
// this sets the folder status to disabled but does not interrupt it.
|
||||
Folder *f = folderMan->folder( alias );
|
||||
if( f && folderEnabled ) {
|
||||
if (!f) {
|
||||
return;
|
||||
}
|
||||
|
||||
if( folderEnabled ) {
|
||||
// check if a sync is still running and if so, ask if we should terminate.
|
||||
if( f->isBusy() ) { // its still running
|
||||
#if defined(Q_OS_MAC)
|
||||
|
@ -737,7 +719,7 @@ void AccountSettings::slotIgnoreFilesEditor()
|
|||
_ignoreEditor->setAttribute( Qt::WA_DeleteOnClose, true );
|
||||
_ignoreEditor->open();
|
||||
} else {
|
||||
Utility::raiseDialog(_ignoreEditor);
|
||||
ownCloudGui::raiseDialog(_ignoreEditor);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -60,7 +60,6 @@ public slots:
|
|||
void slotOpenOC();
|
||||
void slotUpdateFolderState( Folder* );
|
||||
void slotDoubleClicked( const QModelIndex& );
|
||||
void slotFolderOpenAction( const QString& );
|
||||
void slotSetProgress(const QString& folder, const Progress::Info& progress);
|
||||
void slotButtonsSetEnabled();
|
||||
|
||||
|
|