This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// To be used with Alfresco JS Console. Select folder in js console to create export package for | |
var exportaction = actions.create("export"); | |
exportaction.parameters["store"] = "workspace://SpacesStore"; | |
exportaction.parameters["package-name"] = space.properties.name + "_export.acp"; | |
exportaction.parameters["destination"] = space.parent; | |
exportaction.parameters["include-children"] = true; | |
exportaction.parameters["include-self"]=true; | |
exportaction.parameters["encoding"]="UTF-8"; | |
exportaction.execute(space); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ------- | |
# Script to patch for Imagetragick | |
# | |
# Copyright 2013-2016 Loftux AB, Peter Löfgren | |
# Distributed under the Creative Commons Attribution-ShareAlike 3.0 Unported License (CC BY-SA 3.0) | |
# ------- | |
IMAGEMAGICKPOLICYFILE="/etc/ImageMagick/policy.xml" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Delete thumbnails if exists. To be used in Alfresco javascript console. Starts from selected space | |
recurse(space, function(node) { | |
var doclib = node.getThumbnail('doclib'); | |
var webpreview = node.getThumbnail('webpreview'); | |
var webpreview2 = node.getThumbnail('web-preview'); | |
var imgpreview = node.getThumbnail('imgpreview'); | |
var pdf = node.getThumbnail('pdf'); | |
if(doclib){ | |
doclib.remove(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//***** Script variant one, fore one user ******** | |
var userid = "userid01"; | |
var searchobj = { | |
query:'PATH:"/app:company_home/st:sites/cm:surf-config/cm:components/*" AND @cm\:name:"*'+userid+'*"', | |
language: 'fts-alfresco' | |
}; | |
var nodes = search.query(searchobj); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Prerequisite | |
One instance of Alfresco on mysql, one postgresl of exactly the same version (schema version). | |
Step 1. Dump database | |
mysqldump --port 3306 -u alfresco --password=alfloftux -h 127.0.0.1 --databases alfresco --skip-comments --skip-extended-insert --no-create-db --hex-blob --default-character-set=utf8 --skip-triggers --compact --no-create-info --skip-quote-names > mydump.sql | |
Step 2. Dump local Postgres schema | |
You can install a clean version of Alfresco to use as for schema dump | |
(need to insert command for dump here) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Convert a subversion repository path to git | |
# Author: Peter Löfgren, Loftux AB | |
# The subversion path to export | |
URL="https://share-extras.googlecode.com/svn/trunk/Media Preview" | |
# First revision this path exists | |
STARTREV=2 | |