😶🌫️
This file contains hidden or 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
/* | |
Watch out, os.IsExist(err) != !os.IsNotExist(err) | |
They are error checkers, so use them only when err != nil, and you want to handle | |
specific errors in a different way! | |
Their main purpose is to wrap around OS error messages for you, so you don't have to test | |
for Windows/Unix/Mobile/other OS error messages for "file exists/directory exists" and | |
"file does not exist/directory does not exist" |
This file contains hidden or 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
apt-get install libsm6 libice6 libxrender1 libxext6 fontconfig |
This file contains hidden or 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
-module(chat). | |
-export([server/1, client/0]). | |
server(Clients) -> | |
receive | |
{client, Client} -> | |
server(Clients ++ [Client]); | |
{msg, Message} -> | |
send_message(Message, Clients), |
This file contains hidden or 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
importClass(Packages.org.springframework.web.context.ContextLoader); | |
importClass(Packages.org.alfresco.service.cmr.repository.TransformationOptions); | |
var context = ContextLoader.getCurrentWebApplicationContext(); | |
var alfThumbnailService = context.getBean("thumbnailService"); | |
alfThumbnailService.updateThumbnail(document.getThumbnail("webpreview").nodeRef, new TransformationOptions()); |