Skip to content

Instantly share code, notes, and snippets.

@mcasperson
mcasperson / gist:2f48913aaec43a3322c8
Created May 18, 2014 22:05
Sample AsciiDoc that results in an illegal <phrase> in a <literal>
:numbered:
:doctype: book
:toc: left
:icons: font
[[sect-overview-of-browsersim]]
== Overview of BrowserSim
[[about-browsersim]]
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<?asciidoc-toc?>
<?asciidoc-numbered?>
<book xmlns="http://docbook.org/ns/docbook" lang="en">
<bookinfo>
<title>Untitled</title>
<date>2014-05-19</date>
</bookinfo>
<chapter id="sect-overview-of-browsersim">
@mcasperson
mcasperson / gist:09848e49f56d4a27b0ab
Created May 19, 2014 03:59
DocBook 4.5 output from asciidoc.txt
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<?asciidoc-toc?>
<?asciidoc-numbered?>
<article xmlns="http://docbook.org/ns/docbook" lang="en">
<articleinfo>
<title>AsciiDoc User Guide</title>
<date>2014-05-19</date>
<author>
<firstname>Stuart</firstname>
@mcasperson
mcasperson / gist:1e66781194edb47a94bf
Created May 19, 2014 22:16
tgroup without tbody
<table frame="all"
rowsep="1" colsep="1">
<title>A table with externally sourced CSV data</title>
<tgroup cols="5">
<colspec colname="col_1" colwidth="11*"/>
<colspec colname="col_2" colwidth="22*"/>
@mcasperson
mcasperson / gist:d4fea8a476d4fdc40a45
Last active August 29, 2015 14:01
PressGang readonly slave
Setup the master server with the following settings in my.cnf (under the [mysqld] section):
log_bin=/var/lib/mysql/mysql-bin
binlog-format=row
server_id=1
expire_log_days=7
Create a MySQL user on the master to perform the replication with:
CREATE USER 'pressgang_slave'@'%' IDENTIFIED BY 'password';
@mcasperson
mcasperson / gist:3f3b49852fe4b688661b
Last active August 29, 2015 14:02
Sample Asciidoc
=== View jQuery Mobile Pages in a Browser
Mobile Web Tools provides an action to easily and quickly open jQuery Mobile pages in web browsers for viewing.
To open a jQuery Mobile page from a file open in the `JBoss Tools HTML Editor`, press `Ctrl` and move the mouse over the `<div>` tag corresponding to the page widget.
Continue to press `Ctrl` and from the menu select one of the options:
@mcasperson
mcasperson / gist:635bbbfd815a7589f0ac
Last active August 29, 2015 14:02
Sample docbook output
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<?asciidoc-toc?>
<?asciidoc-numbered?>
<book xmlns="http://docbook.org/ns/docbook" lang="en">
<bookinfo>
<title>Untitled</title>
<date>2014-06-10</date>
</bookinfo>
<section id="_view_jquery_mobile_pages_in_a_browser">
@mcasperson
mcasperson / gist:d0c0a5320d051486cd56
Last active April 13, 2017 17:12
Wildfly MySQL XA Datasource Configuration
<?xml version="1.0"?>
<xa-datasource jndi-name="java:jboss/datasources/settings_db" pool-name="setting_db" enabled="true" use-ccm="true">
<xa-datasource-property name="ServerName">
server
</xa-datasource-property>
<xa-datasource-property name="DatabaseName">
database
</xa-datasource-property>
<driver>mysql</driver>
<xa-pool>
@mcasperson
mcasperson / gist:c8a313b1e2a9cc566375f24424787b6e
Created January 12, 2018 02:12
Terraform JSON with S3 state
{
"terraform": [{
"backend": [{
"s3": {
"bucket": "octopus-terraform-demo",
"key": "terraform.tfstate",
"region": "us-east-1"
}
}]
}],
2018-01-13T06:47:44.434989+00:00 app[web.1]: 2018-01-13 06:47:44,430 WARN [org.hibernate.tool.schema.internal.ExceptionHandlerLoggedImpl] (ServerService Thread Pool -- 17) GenerationTarget encountered exception accepting command : Error executing DDL via JDBC Statement: org.hibernate.tool.schema.spi.CommandAcceptanceException: Error executing DDL via JDBC Statement
2018-01-13T06:47:44.435001+00:00 app[web.1]: at org.hibernate.tool.schema.internal.exec.GenerationTargetToDatabase.accept(GenerationTargetToDatabase.java:67)
2018-01-13T06:47:44.435003+00:00 app[web.1]: at org.hibernate.tool.schema.internal.SchemaDropperImpl.applySqlString(SchemaDropperImpl.java:373)
2018-01-13T06:47:44.435004+00:00 app[web.1]: at org.hibernate.tool.schema.internal.SchemaDropperImpl.applySqlStrings(SchemaDropperImpl.java:358)
2018-01-13T06:47:44.435005+00:00 app[web.1]: at org.hibernate.tool.schema.internal.SchemaDropperImpl.applyConstraintDropping(SchemaDropperImpl.java:330)
2018-01-13T06:47:44.435006+00:00 app[web.1]