Skip to content

Instantly share code, notes, and snippets.

e7f34b6faaa6:/var/www/html# composer require 'drupal/core-composer-scaffold:9.5.9' --with-all-dependencies
./composer.json has been updated
Running composer update drupal/core-composer-scaffold --with-all-dependencies
Loading composer repositories with package information
Info from https://repo.packagist.org: #StandWithUkraine
Updating dependencies
Nothing to modify in lock file
Writing lock file
Installing dependencies from lock file (including require-dev)
Nothing to install, update or remove
<http://www.side-sante.fr/sides> <rdf:type> <owl:Ontology> .
<http://www.side-sante.fr/sides> <owl:backwardCompatibleWith> <http://www.side-sante.fr/sides/version/1.0> .
<http://www.side-sante.fr/sides> <owl:versionIRI> <http://www.side-sante.fr/sides/version/2.0> .
<:01_definition> <rdf:type> <:EDN_Rubric> .
<:02_prevalence_epidemiology> <rdf:type> <:EDN_Rubric> .
<:03_physiopathology> <rdf:type> <:EDN_Rubric> .
<:04_diagnosis> <rdf:type> <:EDN_Rubric> .
<:05_multimediaContent> <rdf:type> <:EDN_Rubric> .
<:06_emergencyIdentification> <rdf:type> <:EDN_Rubric> .
<:07_etiology> <rdf:type> <:EDN_Rubric> .
@asanchez75
asanchez75 / access_postgresql_with_docker.md
Created September 20, 2022 09:21 — forked from MauricioMoraes/access_postgresql_with_docker.md
Allow Docker Container Access to Host's Postgres Database on linux (ubuntu)

You have to do 2 things in order to allow your container to access your host's postgresql database

  1. Make your postgresql listen to an external ip address
  2. Let this client ip (your docker container) access your postgresql database with a given user

Obs: By "Host" here I mean "the server where docker is running on".

Make your postgresql listen to an external ip address

Find your postgresql.conf (in case you don't know where it is)

$ sudo find / -type f -name postgresql.conf

@asanchez75
asanchez75 / iterm.el
Created September 13, 2022 14:41 — forked from johnmastro/iterm.el
Send text from Emacs to iTerm
;;; iterm.el - Send text to a running iTerm instance
(require 'pcase)
(require 'thingatpt)
;; To match SublimeText's key binding:
;; (global-set-key (kbd "<C-return>") 'iterm-send-text)
(defvar iterm-default-thing 'line
"The \"thing\" to send if no region is active.
@asanchez75
asanchez75 / ProofOfConceptSparkCuctomListener.scala.txt
Created August 22, 2022 20:31 — forked from LucaCanali/ProofOfConceptSparkCuctomListener.scala.txt
Proof-of-concept code of how to extend Spark listeners for custom monitoring of Spark metrics
// Proof-of-concept code of how to extend Spark listeners for custom monitoring of Spark metrics
// When using this from the spark-shell, use the REPL command :paste and copy-paste the following code
// Tested on Spark 2.1.0, March 2017
import org.apache.spark.scheduler._
import org.apache.log4j.LogManager
val logger = LogManager.getLogger("CustomListener")
class CustomListener extends SparkListener {
override def onStageCompleted(stageCompleted: SparkListenerStageCompleted): Unit = {
[PrefixDeclaration]
: http://example.org/voc#
ex: http://example.org/
owl: http://www.w3.org/2002/07/owl#
rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
xml: http://www.w3.org/XML/1998/namespace
xsd: http://www.w3.org/2001/XMLSchema#
foaf: http://xmlns.com/foaf/0.1/
obda: https://w3id.org/obda/vocabulary#
rdfs: http://www.w3.org/2000/01/rdf-schema#
@asanchez75
asanchez75 / smartcheck.sh
Created June 15, 2022 13:02 — forked from tommybutler/smartcheck.sh
Script to quickly scan the S.M.A.R.T. health status of all your hard drive devices in Linux (at least all the ones from /dev/sda to /dev/sdzz). You need smartctl installed on your system for this script to work, and your hard drives need to have S.M.A.R.T. capabilities (they probably do).
#!/bin/bash
# install the smartctl package first! (apt-get install smartctl)
if sudo true
then
true
else
echo 'Root privileges required'
@asanchez75
asanchez75 / lifehack.css
Created April 18, 2022 16:33 — forked from angelolev/lifehack.css
Script to see HTML elements containers and properties
<style>
html * {
background: rgba(255, 0, 0, .1);
box-shadow: 0 0 0 1px red;
}
</style>
@asanchez75
asanchez75 / gist:2ce9a19687053213a2b395c946ec91fd
Created April 3, 2022 16:18 — forked from taniwallach/gist:f1f6c81ce19b7d68f74d4b71d1db57a2
Installing HP-107w on Linux (using HP's unified linux driver ULDLINUX_V1.00.39_00.12.zip)
HP provides a downloadable "driver" for Linux for the HP 107w printer but there are NO reasonable install instructions provided, and following the "obvious" install process did not get the printer working.
The closest I found to HP install instuctions once I knew more is https://support.hp.com/in-en/document/c05588857
Since I found this annoying and wasted more time on getting this printer working under Linux, I'm sharing a summary of what did work (on Debian 10).
1. Download the driver file from https://support.hp.com/us-en/drivers/selfservice/hp-laser-100-printer-series/24494339/model/24494342 from under the "Basic Drivers" menu for when the OS is set to Linux.
The current version now is: "HP Laser 100 and HP Color Laser 150 Printer series Print Driver V1.00.39:00.12 5.9 MB Mar 20, 2019"
root@vmi465483:~# cat /etc/nginx/sites-enabled/dspace.conf
server {
server_name repositorio.unijuanpablo.edu.pe;
root /var/www/html/;
client_max_body_size 2000m;
location / {
return 301 http://repositorio.unijuanpablo.edu.pe/xmlui/;
}