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
| import java.io.File; | |
| import java.io.FileInputStream; | |
| import java.io.FileNotFoundException; | |
| import java.io.InputStream; | |
| import java.util.ArrayList; | |
| import java.util.List; | |
| import javax.annotation.PostConstruct; | |
| import javax.faces.bean.ApplicationScoped; | |
| import javax.faces.bean.ManagedBean; |
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
| #!/bin/bash | |
| locationstocompress=( "/home" "/var/www" ) | |
| identifier="WEB-1" | |
| megaemail="email@provider.com" | |
| megapass="password" | |
| # Edit below this if you're feeling lucky | |
| masterfile="$identifier-$(date +"%Y-%m-%d").tar.gz" |
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
| #!/bin/bash | |
| # Startup script for Glassfish. | |
| # | |
| # chkconfig: 2345 95 05 | |
| # description: Start the java application server, glassfish. | |
| # pidfile: /var/run/glassfish.pid | |
| # | |
| # Used and tested on centos 6 | |
| # | |
| # Author: daniel.lindh@fareoffice.com |
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
| import javax.inject.Singleton; | |
| import javax.ws.rs.container.ContainerRequestContext; | |
| import javax.ws.rs.container.ContainerResponseContext; | |
| import javax.ws.rs.container.ContainerResponseFilter; | |
| import javax.ws.rs.core.MultivaluedMap; | |
| import javax.ws.rs.ext.Provider; | |
| import java.io.IOException; | |
| @Singleton | |
| @Provider |
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
| public class HelperResource { | |
| public static void setRequestOptions(ContainerRequestContext requestContext, RequestOptions requestOptions) { | |
| requestContext.setProperty("requestOptions", requestOptions); | |
| } | |
| public static boolean isBodyRequested(ContainerRequestContext requestContext) { | |
| // Do not return a body for head methods, but we might want to calculate paging / headers, etc. | |
| // For now this is getting rewritten as GET by Jersey, but it might be changed later: | |
| // https://java.net/jira/browse/JERSEY-2460 |
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
| package my.application.dao; | |
| import java.util.List; | |
| import my.application.entity.Book; | |
| import my.application.restutil.RequestOptions; | |
| public interface BookPersister { | |
| List<Book> getBooks(RequestOptions requestOptions); | |
| } |
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
| # http://blog.teamtreehouse.com/the-absolute-beginners-guide-to-sass | |
| # Enter the folder you want to convert in your terminal and type in: | |
| # --------------------------------------------------------------------- | |
| # sudo apt get install ruby-sass | |
| # --------------------------------------------------------------------- | |
| sass-convert --from sass --to scss -R . | |
| # where -R means recursively and . means the current directory. |
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
| @echo off | |
| REM instructions from: https://groups.google.com/d/msg/cefsharp/BJLMXl9c204/HMJlp8mZzF0J | |
| REM seems like partial instructions copied to SO: http://stackoverflow.com/questions/8033495/chromium-embedded-framework-mp3-support | |
| REM all chromium releases: https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding.md#markdown-header-release-branches | |
| REM 2272 - latest chromium with npapi (41) | |
| REM there is a commits list: https://bitbucket.org/chromiumembedded/cef/branch/2272 | |
| REM https://github.com/cefsharp/CefSharp | |
| REM cef builds http://www.magpcss.net/cef_downloads/ | |
| REM https://cefbuilds.com |
NewerOlder