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
# copy a repository and its tags into a second, third repositoty | |
# (c) Abdelkrim Boujraf, http://www.alt-f1.be | |
# Imagine that your original repository is on bitbucket.org | |
[email protected]:alt-f1.be/data_visualization.git | |
# ADD REMOTE PUSH URL's for gitlab and github | |
# It will change the remote.origin.pushurl config entry. | |
# Now pushes will send to both of these destinations, rather than the fetch URL. | |
# https://gist.github.com/rvl/c3f156e117e22a25f242 |
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
// see https://www.youtube.com/watch?v=Zbm3hjPjQMk | |
import 'package:flutter/material.dart'; | |
class InheritedSettings extends InheritedWidget{ | |
final SettingsSwitchesStatefulWidget settingsSwitchesStatefulWidget; | |
final TechnicalInfoSection technicalInfoSection; | |
InheritedSettings({this.SettingsSwitchesStatefulWidget, Widget child}): super(child: child); |
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
# Author Abdelkrim Boujraf, ALT-F1 SPRL | |
import os | |
dir_to_delete = '/kaggle/working/' | |
with os.scandir(dir_to_delete) as entries: | |
for entry in entries: | |
file_to_delete = f"{dir_to_delete}{entry.name}" | |
if os.path.isfile(file_to_delete): | |
print(file_to_delete) | |
os.remove(file_to_delete) |
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/bash | |
# https://dev.to/ope/securing-your-azure-web-app-with-let-s-encrypt-4g99 | |
echo please indicate the domaine name i.e. alt-f1.be | |
read domain_name | |
# domain_name=betterop.alt-f1.be | |
sudo certbot certonly -d $domain_name --manual --preferred-challenges dns |
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
import os | |
import shutil | |
def is_venv_directory(path): | |
""" | |
Check if the given path is a virtual environment directory. | |
""" | |
return ( | |
os.path.isdir(path) and | |
(os.path.isfile(os.path.join(path, 'bin', 'activate')) or |
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
import os | |
import shutil | |
def is_venv_directory(path): | |
""" | |
Check if the given path is a virtual environment directory. | |
""" | |
return ( | |
os.path.isdir(path) and | |
(os.path.isfile(os.path.join(path, 'bin', 'activate')) or |
OlderNewer