This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Get a list of open issues using the 'gh' command from GitHub. | |
# By default this gives at most 30 answers. | |
# We print only the number. | |
# Then we iterate over these issues and check each one, offering to close it. | |
# There are a few sample queries. | |
# Make sure one of the ISSUES commands is uncommented. | |
# 1. Get open issues last updated before 2019. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# Original: https://gist.github.com/mauritsvanrees/b30c9a8ff7075bfc38e873f03c9ebefe | |
# | |
# Sometimes towncrier is just too hard to understand, or it does too much, | |
# or the combination with zest.releaser is too restricting, | |
# especially when you want to make some manual edits after running towncrier. | |
# So try something out. | |
# Ideas for commands: | |
# - newssnippet create: create a news snippet with a correct name, compatible with towncrier. | |
# - newssnippet print/list: print all news snippets. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# https://gist.github.com/mauritsvanrees/c47e974e418c707a626200cb6561405b | |
# https://community.plone.org/t/creating-constraints-and-requirements-from-buildout-config/10296 | |
# from configparser import ConfigParser | |
from zc.buildout import buildout | |
import re | |
# We read this buildout config file: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check the automatic and manual redirects in all Plone Sites. | |
# Run this with: | |
# bin/instance run check-redirects.py | |
# or with extra options: --verbose --fix --site=Plone | |
from plone.app.redirector.interfaces import IRedirectionStorage | |
from zope.component import getUtility | |
from zope.component.hooks import setSite | |
import argparse | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Latest public version: | |
# https://gist.github.com/mauritsvanrees/92c40bc16ceaf3c375d81c995b4552c4 | |
# Goal: | |
# Make initial changes in a git project to use towncrier | |
# instead of manually editing CHANGES.rst. | |
# Create a standard pyproject.toml file. | |
TOML="pyproject.toml" | |
if ! test -e $TOML; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Add Plone 5.1 classifier when Plone 5.0 classifier is there. | |
Usage: | |
cd <coredev 5.1 branch> | |
cd src | |
python2.7 add51.py plone.app.favoritepackage | |
python2.7 add51.py * | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Latest version: | |
# https://gist.github.com/mauritsvanrees/eb69adbb51747834808f6847c140b706 | |
# Run this in a checkout of a Plone package to get some information, | |
# like which version is used in which Plone version. | |
# Hardly related note: sort coredev checkouts by date that they were added: | |
# git blame checkouts.cfg | cut -b29- | sort -g | |
# The current directory as package name. | |
package=$(basename $(pwd)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Grab version files from dist.plone.org for each Plone version. | |
Original location: | |
https://gist.github.com/mauritsvanrees/99cb4a25b622479e7dc3 | |
Goal: grep through these files to see which version of a package is | |
used in which Plone version. | |
Usage: | |
$ virtualenv-2.7 . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
############################################################################## | |
# | |
# Copyright (c) 2015 Zope Foundation and Contributors. | |
# All Rights Reserved. | |
# | |
# This software is subject to the provisions of the Zope Public License, | |
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. | |
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED | |
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
############################################################################## | |
# | |
# Copyright (c) 2015 Zope Foundation and Contributors. | |
# All Rights Reserved. | |
# | |
# This software is subject to the provisions of the Zope Public License, | |
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. | |
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED | |
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
NewerOlder