Mục bình luận của Luyện Code có sử dụng Markdown để tiện cho chúng ta sử dụng. Hướng dẫn ngắn gọn sau đây sẽ giúp bạn sử dụng markdown cơ bản để viết bình luận đẹp hơn. Tại mỗi ví dụ, phía trên sẽ là ví dụ và phía dưới sẽ là kết quả của ví dụ đó.
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 | |
set -e | |
echo "🚮 Gỡ Docker và containerd cũ nếu có..." | |
sudo systemctl stop docker || true | |
sudo apt remove -y docker docker.io docker-engine containerd containerd.io runc || true | |
sudo apt purge -y docker docker.io docker-engine containerd containerd.io runc || true | |
sudo apt autoremove -y || true |
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 | |
# Unmask Docker services | |
echo "Đang khởi tạo hệ thống" | |
sudo apt update > /dev/null 2>&1 | |
sudo apt install -y caffeine > /dev/null 2>&1 | |
sudo systemctl unmask docker > /dev/null 2>&1 | |
sudo systemctl unmask docker.socket > /dev/null 2>&1 | |
sudo systemctl start docker > /dev/null 2>&1 | |
sudo systemctl start docker.socket > /dev/null 2>&1 |
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 | |
# Function to display usage information | |
usage() { | |
echo "Usage: $0 /path/to/input.mp4 [ /path/to/output_directory ]" | |
exit 1 | |
} | |
# Check if at least one argument (input file) is provided | |
if [ $# -lt 1 ]; then |
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
/* | |
<https://stackoverflow.com/questions/40296831/is-it-possible-to-force-a-copy-of-a-protected-google-doc> | |
NOTE - 2021-05-24 | |
----------------- | |
The script below isn't the fastest way to copy-and-paste from a protected | |
Google Doc. Before trying it, I'd suggest following MikoFrosty's advice from | |
the comments: |
⚠️ Note 2023-01-21
Some things have changed since I originally wrote this in 2016. I have updated a few minor details, and the advice is still broadly the same, but there are some new Cloudflare features you can (and should) take advantage of. In particular, pay attention to Trevor Stevens' comment here from 22 January 2022, and Matt Stenson's useful caching advice. In addition, Backblaze, with whom Cloudflare are a Bandwidth Alliance partner, have published their own guide detailing how to use Cloudflare's Web Workers to cache content from B2 private buckets. That is worth reading,
Picking the right architecture = Picking the right battles + Managing trade-offs
- Clarify and agree on the scope of the system
- User cases (description of sequences of events that, taken together, lead to a system doing something useful)
- Who is going to use it?
- How are they going to use it?
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
# Set master image | |
FROM php:7.3-fpm-alpine | |
MAINTAINER Rajesh Chaudhary <[email protected]> | |
# Copy composer.lock and composer.json | |
#COPY composer.lock composer.json /var/www/ | |
# Set working directory | |
WORKDIR /var/www |
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 | |
echo | |
echo "-----------------------------" | |
echo " ╔╦╗╔═╗╔═╗╔╦╗╔═╗╔╦╗╔═╗╔╗╔" | |
echo " ║║║╠═╣╚═╗ ║ ║ ║ ║║║ ║║║║" | |
echo " ╩ ╩╩ ╩╚═╝ ╩ ╚═╝═╩╝╚═╝╝╚╝" | |
echo " Installer for Sakura VPS" | |
echo " (CentOS7x with KUSANAGI)" | |
echo "-----------------------------" | |
echo |
NewerOlder