This file contains hidden or 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 -*- | |
| import datetime | |
| from dateutil import parser as dt_parser | |
| class TimePlanner: | |
| holidays = None | |
| weekend = None | |
| working_hours = None |
This file contains hidden or 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 | |
| eval "export $(egrep -z DBUS_SESSION_BUS_ADDRESS /proc/$(pgrep -u $LOGNAME gnome-session)/environ)" | |
| /usr/bin/notify-send -i face-wink "Пятиминутка" "Сделай паузу!" | |
| /bin/sleep 2 | |
| loginctl lock-session 3 |
This file contains hidden or 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 | |
| sleep 10 | |
| export DISPLAY=:0 | |
| /usr/bin/xset -dpms | |
| /usr/bin/xset s off | |
| sudo /usr/bin/nvidia-smi -pm 1 | |
| sudo /usr/bin/nvidia-smi -pl 90 |
This file contains hidden or 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
| ln -s /etc/nginx/sites-available/domain.conf /etc/nginx/sites-enabled/domain.conf |
This file contains hidden or 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 | |
| class CustomCompare(object): | |
| def __init__(self, obj, order): | |
| self.obj = obj | |
| self.order = order | |
| def __lt__(self, other): | |
| return self._index_of(self.obj) < self._index_of(other.obj) |
This file contains hidden or 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 | |
| sudo modprobe ec_sys write_support=1 | |
| echo -n -e "\xc2" | sudo dd of="/sys/kernel/debug/ec/ec0/io" bs=1 count=1 conv=notrunc seek=242 |
This file contains hidden or 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
| stages: | |
| - child-pipeline-generator | |
| - child-pipeline-trigger | |
| generate-child-pipeline: | |
| stage: child-pipeline-generator | |
| image: python:3.9-slim-buster | |
| script: | |
| - python3 main.py | |
| artifacts: |
This file contains hidden or 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 | |
| # That snippet fixes the issue related with shasum path on Manjaro Arch Linux (Gnome) | |
| # /usr/bin/shasum: No such file or directory | |
| sudo ln -s /usr/bin/core_perl/shasum /usr/bin/shasum |
This file contains hidden or 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
| # If odoo deployed in docker | |
| # set the system parameter "report.url" as "http://localhost:8069" |
This file contains hidden or 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
| sudo nano /etc/default/grub | |
| # Add "mem_sleep_default=deep" to GRUB_CMDLINE_LINUX_DEFAULT line | |
| # Save file | |
| sudo update-grub | |
| sudo reboot |
OlderNewer