Skip to content

Instantly share code, notes, and snippets.

View monperrus's full-sized avatar

Martin Monperrus monperrus

View GitHub Profile
@monperrus
monperrus / notes.md
Last active September 8, 2024 08:32
Showing all hidden comments on Github

Problem

Github collapses comments when there are too many.

When you open a page and Ctrl-F, you don't find what you want.

Solution

Automatically loads all comments at page start with Greasemonkey / Tampermonhey / Violentmonkey userscript:

@monperrus
monperrus / github-show-all-comments.user.js
Last active September 10, 2024 10:45
Greasemonkey / Tampermonhey / Violentmonkey userscript to automatically show all comments on Github
// ==UserScript==
// @name Github Show All Hidden Comments
// @description Load and show all comments on Github, credits https://github.com/refined-github/refined-github/issues/1892#issuecomment-1044913449
// @url https://gist.github.com/monperrus/a094ccf2941c4c76f4ea77cec252ad77
// @namespace monperrus
// @author @rentecaaron
// @license Public domain
// @grant none
// @version 1.0.0
//
@monperrus
monperrus / Apple Developer Agreement June 2024.md
Created August 26, 2024 05:33
Apple Developer Agreement June 2024

THIS IS A LEGAL AGREEMENT BETWEEN YOU AND APPLE INC. ("APPLE") STATING THE TERMS THAT GOVERN YOUR PARTICIPATION AS AN APPLE DEVELOPER. PLEASE READ THIS APPLE DEVELOPER AGREEMENT (“AGREEMENT”) BEFORE PRESSING THE "AGREE" BUTTON AND CHECKING THE BOX AT THE BOTTOM OF THIS PAGE. BY PRESSING "AGREE," YOU ARE AGREEING TO BE BOUND BY THE TERMS OF THIS AGREEMENT. IF YOU DO NOT AGREE TO THE TERMS OF THIS AGREEMENT, PRESS "CANCEL".

Apple Developer Agreement

  1. Relationship With Apple; Apple Account and Password. You understand and agree that by registering with Apple to become an Apple Developer (“Apple Developer”), no legal partnership or agency relationship is created between you and Apple. You agree not to represent otherwise. You also certify that you are at least thirteen years of age and you represent that you are legally permitted to register as an Apple Developer. This Agreement is void where prohibited by law and the right to register as an Apple Developer is not granted in such jurisdictions. Unless other
@monperrus
monperrus / capabilities.md
Created August 14, 2024 19:55
IMAP capabilities of Microsoft Exchange

IMAP capabilities of Microsoft Exchange (version 15.2.1544.11):

CAPABILITY IMAP4 IMAP4rev1 AUTH=PLAIN AUTH=NTLM AUTH=GSSAPI SASL-IR UIDPLUS MOVE ID UNSELECT XPROXY3 CLIENTNETWORKPRESENCELOCATION CHILDREN IDLE NAMESPACE LITERAL+

@monperrus
monperrus / fcgi_client.py
Created August 6, 2024 13:25
A standalone FastCGI client in Python 3
#
@monperrus
monperrus / inject_spoon_snapshot.py
Created August 5, 2024 15:54
inject_spoon_snapshot.py
#! /bin/python3
"""Script for injecting the latest SNAPSHOT version of Spoon into all pom.xml
files it finds in the current working directory or any subdirectory.
Requires the ``defusedxml`` package to be installed separately.
This script is compatible with Python 3.5+
"""
import xml.etree.ElementTree as ET
import subprocess
@monperrus
monperrus / build.sh
Last active August 5, 2024 16:57
spoon build.sh
#!/bin/bash
#
# Compiles an open-source project, spoons the project, runs the tests
# and checks at each step if there aren't errors. To execute this
# script, create a job in jenkins.
#
#
# Typical usage:
#
# $ cd my-maven-project-with-pom
@monperrus
monperrus / export-nextcloud-notes-to-enex.py
Last active August 2, 2024 06:00
export Nextcloud Notes to the Enex file format for importing into Evernote or Joplin
#!/usr/bin/python3
# export Nextcloud Notes to the Enex file format for importing into Evernote or Joplin
#
# in Joplin use File > Import > ENEX - EverNote Export File (as Markdown)
#
# reference documentation about ENEX file format: https://evernote.com/blog/how-evernotes-xml-export-format-works
#
# Author: Martin Monperrus
# License: Public domain
# URL: https://gist.github.com/monperrus/93b5fe05025a726b13f64a971e9127c2

what is research taste?

"Research taste" is a term that refers to a researcher's ability to identify and pursue high-quality, impactful, and innovative research questions and projects. It encompasses several attributes:

  1. Judgment: The ability to discern which problems are worth solving and which questions are likely to lead to significant advancements in the field.
  2. Creativity: The capacity to think outside the box and come up with novel approaches and ideas.
  3. Knowledge: A deep understanding of the current state of the field, including key theories, methodologies, and findings.
  4. Intuition: An almost instinctive sense of what will work and what won't, often developed through experience.
  5. Relevance: The ability to choose research topics that are not only interesting but also relevant to current societal, scientific, or technological needs.
curl 'https://www.computer.org/csdl/api/v1/graphql' -X POST --data-raw '{"variables":{"articleId":"1WXSS1AygtG"},"query":"query ($articleId: String!) {\n issue: periodicalIssueByArticleId(articleId: $articleId) {\n id\n title\n year\n issueNum\n idPrefix\n pubType\n volume\n year\n label\n downloadables {\n hasCover\n __typename\n }\n __typename\n }\n article: articleById(articleId: $articleId) {\n id\n doi\n abstract\n abstracts {\n abstractType\n content\n __typename\n }\n normalizedAbstract\n title\n normalizedTitle\n fno\n hasPdf\n idPrefix\n keywords\n authors {\n givenName\n surname\n fullName\n affiliation\n __typename\n }\n replicability {\n isEnabled\n codeDownloadUrl\n codeRepositoryUrl\n __typename\n }\n showBuyMe\n showRecommendedArticles\n isOpenAccess\n issueNum\n pubDate\n pubType\n pages\n year\n issn\n isbn\