- Download the latest zsh package: https://packages.msys2.org/package/zsh?repo=msys&variant=x86_64
Example:
zsh-5.7.1-1-x86_64.pkg.tar.xz
import javax.persistance.TypedQuery; | |
import org.hibernate.engine.spi.SessionImplementor; | |
import org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory; | |
import org.hibernate.hql.spi.QueryTranslator; | |
public class JpaToSQL { | |
TypedQuery<T> query = null; | |
public static void main(String[] args) { |
@Component | |
@Scope("prototype") | |
public class RequestHandler extends BaseRequestHandler<List<PositionEstablishment>> { | |
@Autowired | |
private PositionEstablishmentRepository positionEstablishmentRepository; | |
Date asAtDate; | |
private List<com.jemini.base.model.position.PositionEstablishment> establishments = new ArrayList<>(); | |
private List<PositionDateEffective> positionDateEffectives; | |
public Date getAsAtDate() {return asAtDate;} |
Example:
zsh-5.7.1-1-x86_64.pkg.tar.xz
@SpringBootTest | |
class DBquerryAsListTest { | |
@Autowired | |
@Qualifier("testSetupDataSource") | |
DataSource testSetupDataSource; | |
JdbcTemplate jdbcTemplate; | |
@Test |
// import(s) are omitted | |
@SpringBootTest | |
@Log4J2 | |
class DAOTests { | |
JdbcTemplate jdbcTemplate; | |
@Autowired DataSource testSetupDataSource; | |
@BeforeEach | |
void setup1() throws SQLException { //using Java String & JdbcTemplate | |
jdbcTemplate = new JdbcTemplate(testSetupDataSource); |
#!/bin/bash | |
# https://www.aandcp.com/launchdaemons-and-mac-os-x-openvpn-as-an-example | |
### FURTHER TUNNELING ############################ | |
# You can enable unreachable URLs by | |
# Pick the host from the URI you can't reach and find its IPs by running, e.g. | |
# dig vw-bellhop.test.bussys.trimble.com +noall +answer | |
# Then followed by for each IP address, add the route | |
# sudo route add 44.236.79.253/32 -interface utun0 | |
# |
This can reduce files to ~15% of their size (2.3M to 345K, in one case) with no obvious degradation of quality.
ghostscript -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/printer -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf
Other options for PDFSETTINGS:
#!/bin/bash | |
changed=`tempfile -p changed -s .txt` # For macOs, see: https://stackoverflow.com/q/19408005/2234369 | |
nochanges=`tempfile -p nochanges -s .txt` | |
updated=`tempfile -p updated -s .txt` | |
cantupd=`tempfile -p cantupd -s .txt` | |
notonAKAdev=`tempfile -p notonAKAdev -s .txt` | |
switchedto=`tempfile -p switchedto -s .txt` | |
failedtoswitch=`tempfile -p failedtoswitch -s .txt` | |
# Setting default values |
Simple collection of Groovy scripts to help me maintain some Jenkins systems.
See also https://wiki.jenkins-ci.org/display/JENKINS/Jenkins+Script+Console
##################### | |
# | |
# Use this with or without the .gitattributes snippet with this Gist | |
# create a fixle.sh file, paste this in and run it. | |
# Why do you want this ? Because Git will see diffs between files shared between Linux and Windows due to differences in line ending handling ( Windows uses CRLF and Unix LF) | |
# This Gist normalizes handling by forcing everything to use Unix style. | |
##################### | |
# Fix Line Endings - Force All Line Endings to LF and Not Windows Default CR or CRLF |