Skip to content

Instantly share code, notes, and snippets.

View Bachstelze's full-sized avatar

Wagtail Bachstelze

View GitHub Profile
@Bachstelze
Bachstelze / gist:b6e83881f0608816ba444b6394eafa58
Created June 7, 2021 15:41
Bootstrap migration from 3 to 4 to 5
import os
import shutil
import re
# insert you local path into the template_path
# the script is migrating the subdirectories and files of the templates into a folder copy
template_path = "/weblate/templates/"
diff_3_to_4 = {
'@media (min-width: $screen-xs-min) and (max-width: $screen-sm-max)': '@media (min-width: map-get($grid-breakpoints, xs)) and (max-width: map-get($grid-breakpoints, xs))',