Skip to content

Instantly share code, notes, and snippets.

View amanaplan's full-sized avatar

Christian Stück amanaplan

  • St. Petersburg, FL
View GitHub Profile
@amanaplan
amanaplan / gist:078549de0c9566324f41ea07f200eb8f
Last active April 29, 2024 01:59 — forked from mattes/gist:40b5fac8231ca567e94416e7c88d2c10
Multiple Google Chrome instances on MacOS
# http://peter.sh/experiments/chromium-command-line-switches/
mkdir -p /tmp/t1
open -na "Google Chrome" --args --user-data-dir=/tmp/t1 --remote-debugging-port=9222 --disable-features=EnforcePrivacySandboxAttestations,FledgeEnforceKAnonymity
# protip: press cmd+h to hide window
@amanaplan
amanaplan / README.md
Created March 7, 2023 19:01 — forked from cgagner/README.md
Electron client certification test

Electron Client Certificate Test

Electron smart card authentication is not working on Linux. The smart card authentication relies on client certifications. This gist has instructions for testing client certifications, which will be used to test smart card authentication.

Simple example

The main.js handles the 'select-client-certificate' event from the

@amanaplan
amanaplan / README.md
Created July 12, 2021 03:46 — forked from bekce/README.md
ldap server with mysql backend

I wanted to build an LDAP server that queries a MySQL server to fetch users and check their passwords. It is mainly used for old software that does not work with custom OAuth2 providers. Redmine is an example of this.

Instructions:

  1. Create the database and table with insert.sql
@amanaplan
amanaplan / gist:d9136200b10736e01f8238f4fa44f9f1
Created October 4, 2017 13:26 — forked from phayes/gist:2770495
Manually rendering ctools-content-type
<?
ctools_include('plugins');
ctools_include('context');
ctools_include('content');
$plugin_id = 'super_pane';
$plugin = ctools_get_plugins('ctools','content_types', $this->options['field'], $plugin_id);
$conf = array() // array of configuration to pass to the content-type
@amanaplan
amanaplan / gist:a7fba8c17472327f103b4416bebc6066
Created June 27, 2017 00:59 — forked from steve-todorov/gist:3671626
PHP Array key search for matching string.
<?php
/**
* Search through an array for a matching key.
*
* Examples:
* <code>
* $array = array(
* "database.name" => "my_db_name",
* "database.host" => "myhost.com",
@amanaplan
amanaplan / responsive-modal.css
Created April 6, 2017 15:44 — forked from jameswilson/responsive-modal.css
Drupal Ctools Responsive Modal
/* Override inline dom styles from modal.js */
#modalContent {
position: fixed !important;
top: 12% !important;
bottom: 12% !important;
right: 4% !important;
left: 4% !important;
}
/* Limit max width to 1000px */
div.ctools-modal-content {