Skip to content

Instantly share code, notes, and snippets.

@mks-d
mks-d / head.html
Created November 11, 2018 21:25
Jenkins: Custom OCD3 login page (with Mekom colors)
<style>
html {
font: Helvetica;
color: #3f3f40;
}
div .simple-page {
text-align: center;
}
Original Corrected
Syndrome d'Obrinsky/Prune belly Aplasie congénitale de la musculature abdominale (Syndrome d'Obrinsky)
Rosacee Acné rosacée
Déficience de le marche Difficulté à la marche, non classée ailleurs
@mks-d
mks-d / openmrs_fetch_icd10_diagnoses.sql
Last active October 29, 2018 13:09
MySQL query to fetch OpenMRS ICD-10 diagnoses for Haiti
SELECT
data.uuid,
GROUP_CONCAT(DISTINCT data.name SEPARATOR '; ') AS name,
data.set_name,
GROUP_CONCAT(DISTINCT data.code SEPARATOR '; ') AS 'Mapping'
FROM
(
SELECT
c.uuid,
(
@mks-d
mks-d / ubuntu-install-eclipse.txt
Created September 26, 2017 16:01
Install Ecliipse on Ubuntu
1. Download the Eclipse *installer*, usually named:
eclipse-inst-linux64.tar.gz
2. Unpack it and run eclipse-inst that is inside, just in Nautilus.
3. When done Eclipse should simply be installed in /home/<username>/eclipse
4. The installer might add a desktop file at /usr/share/applications/eclipse.desktop
Edit that file and ensure that the Exec and Icon paths are correct, eg;
Icon=/home/<username>/eclipse/jee-oxygen/eclipse/icon.xpm
@mks-d
mks-d / LiquibaseMigrationTest.java
Created July 13, 2018 21:58
Context sensitive test for OpenMRS Liquibase migrations
public class LiquibaseMigrationTest extends BaseModuleContextSensitiveTest {
public LiquibaseMigrationTest() {
super();
Properties props = getRuntimeProperties();
if (useInMemoryDatabase()) {
String url = "jdbc:h2:mem:openmrs;DB_CLOSE_DELAY=30;LOCK_TIMEOUT=10000;LOCK_MODE=0";
props.setProperty(Environment.URL, url);
}
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openmrs.maven.parents</groupId>
<artifactId>maven-parent-openmrs-module</artifactId>
<version>1.1.0</version>
</parent>
<groupId>org.openmrs.module</groupId>
<artifactId>mergepatientdata</artifactId>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openmrs.module</groupId>
<artifactId>mergepatientdata</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
<artifactId>mergepatientdata-omod</artifactId>
<packaging>jar</packaging>
<name>Merge Patient Data OMOD</name>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openmrs.module</groupId>
<artifactId>mergepatientdata</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
<artifactId>mergepatientdata-api</artifactId>
package org.openmrs.module.attachments;
import java.util.List;
import org.junit.Test;
import org.openmrs.Encounter;
import org.openmrs.Patient;
import org.openmrs.Visit;
import org.openmrs.api.EncounterService;
import org.openmrs.api.PatientService;
@mks-d
mks-d / openmrs-maven-settings.xml
Created February 16, 2018 12:05
OpenMRS-generated ~/.m2/settings.xml
<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd">
<servers>
<server>
<username>${env.BINTRAY_USER}</username>
<password>${env.BINTRAY_API_KEY}</password>
<id>bintray-sdk</id>
</server>
</servers>