-
Make sure your cpu support
kvmwith below command:grep -E "(vmx|svm)" --color=always /proc/cpuinfo -
Make sure BIOS have enable “Virtualization Technology”.
-
User access to
/dev/kvmso add your account into kvm(78) group:
| from discord.ext import commands | |
| import discord | |
| from . import api | |
| from typing import Optional | |
| from discord.app import Option | |
| slash_categories = { | |
| ... | |
| } |
| curl -LO https://github.com/sbingner/llvm-project/releases/download/v10.0.0-1/linux-ios-arm64e-clang-toolchain.tar.lzma | |
| TMP=$(mktemp -d) | |
| tar --lzma -xvf linux-ios-arm64e-clang-toolchain.tar.lzma -C $TMP | |
| pushd $TMP/ios-arm64e-clang-toolchain/bin | |
| find * ! -name clang-10 -and ! -name ldid -and ! -name ld64 -exec mv {} arm64-apple-darwin14-{} \; | |
| find * -xtype l -exec sh -c "readlink {} | xargs -I{LINK} ln -f -s arm64-apple-darwin14-{LINK} {}" \; | |
| popd | |
| mkdir -p $THEOS/toolchain/linux/iphone | |
| mv $TMP/ios-arm64e-clang-toolchain/* $THEOS/toolchain/linux/iphone/ | |
| rm -rf $TMP linux-ios-arm64e-clang-toolchain.tar.lzma |
| # ============================================================ | |
| # GLFW dependency | |
| # ============================================================ | |
| message(STATUS "GLFW dependency") | |
| set(glfw_PREFIX "${CMAKE_CURRENT_BINARY_DIR}/glfw") | |
| set(glfw_INSTALL_DIR "${CMAKE_CURRENT_BINARY_DIR}/glfw") | |
| set(glfw_CMAKE_ARGS | |
| -DCMAKE_INSTALL_PREFIX=${glfw_INSTALL_DIR} | |
| -DGLFW_BUILD_EXAMPLES=OFF |
| # note - excludes __ and _ items | |
| ['author', | |
| 'contributors', | |
| 'coordinates', | |
| 'created_at', | |
| 'destroy', | |
| 'entities', | |
| 'favorite', | |
| 'favorite_count', | |
| 'favorited', |
| #!/bin/sh | |
| # view here: | |
| # https://i.stack.imgur.com/OK3po.png | |
| e=$'\e[' | |
| for n in {0..7}; do | |
| printf "${e}"'38;05;'"${n}"'m%-6s' '('"$n"') ' | |
| done |
This is an unfinished list of remarks on how to write good pseudocode.
Pseudocode is a loosely defined way of transmitting the concept of an algorithm from a writer to a reader. Central is the efficiency of this communication, not the interpretability of the code by an automated program (e.g., a parser).
(Inspired by https://medium.com/@icanhazedit/clean-up-unused-github-rpositories-c2549294ee45#.3hwv4nxv5)
-
Open in a new tab all to-be-deleted github repositores (Use the mouse’s middle click or Ctrl + Click) https://github.com/username?tab=repositories
-
Use one tab https://chrome.google.com/webstore/detail/onetab/chphlpgkkbolifaimnlloiipkdnihall to shorten them to a list.
-
Save that list to some path
-
The list should be in the form of “ur_username\repo_name” per line. Use regex search (Sublime text could help). Search for ' |.*' and replace by empty.
| upstream gitlab { | |
| server 172.17.42.1:10080 fail_timeout=0; | |
| } | |
| # let gitlab deal with the redirection | |
| server { | |
| listen 80; | |
| server_name git.example.com; | |
| server_tokens off; | |
| root /dev/null; |
Let's say somebody temporarily got root access to your system, whether because you "temporarily" gave them sudo rights, they guessed your password, or any other way. Even if you can disable their original method of accessing root, there's an infinite number of dirty tricks they can use to easily get it back in the future.
While the obvious tricks are easy to spot, like adding an entry to /root/.ssh/authorized_keys, or creating a new user, potentially via running malware, or via a cron job. I recently came across a rather subtle one that doesn't require changing any code, but instead exploits a standard feature of Linux user permissions system called setuid to subtly allow them to execute a root shell from any user account from the system (including www-data, which you might not even know if compromised).
If the "setuid bit" (or flag, or permission mode) is set for executable, the operating system will run not as the cur