Skip to content

Instantly share code, notes, and snippets.

View rkJun's full-sized avatar

Juntai Park rkJun

View GitHub Profile
@rkJun
rkJun / esm-package.md
Created July 12, 2021 16:35 — forked from sindresorhus/esm-package.md
Pure ESM package

Pure ESM package

The package linked to from here is now pure ESM. It cannot be require()'d from CommonJS.

This means you have the following choices:

  1. Use ESM yourself. (preferred)
    Use import foo from 'foo' instead of const foo = require('foo') to import the package. Follow the below guide.
  2. If the package is used in an async context, you could use await import(…) from CommonJS instead of require(…).
  3. Stay on the existing version of the package until you can move to ESM.
@rkJun
rkJun / slack-svn.sh
Last active October 30, 2023 18:36
Subversion integration with Slack
#!/bin/bash
#
# Bash script for Subversion integration with Slack
#
# 1. Save this file in /usr/bin as slack-svn
# 2. Make it executable:
# chmod +x /usr/bin/slack-svn
# 3. Put this line at the end of file of your_svn_repo/hooks/post-commit:
# slack-svn $REPOS $REV full_path_to_svn_directory
# 4. Edit this file, especially from line 16-20 and 27 (example given is for Redmine)