Discover gists
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 | |
### steps #### | |
# verify the system has a cuda-capable gpu | |
# download and install the nvidia cuda toolkit and cudnn | |
# setup environmental variables | |
# verify the installation | |
### | |
### to verify your gpu is cuda enable check |
Oh boi, here I give you the solution for that. This document is based on these links:
- https://steamcommunity.com/app/221410/discussions/2/616189106498372437/?l=portuguese&ctp=8
- https://wiki.archlinux.org/title/dnsmasq#NetworkManager
- ValveSoftware/steam-for-linux#3401
My solution seems to be deprecated, there are other solution from the comment on this Gist, that actually works. So, please use that instead, it's way much simpler, and it works.
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
package main | |
import ( | |
"bytes" | |
"encoding/json" | |
"fmt" | |
"net/http" | |
"net/http/httptest" | |
"strings" | |
"sync" |
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
# query | |
curl \ | |
-X POST \ | |
-H "x-api-key: xxx-xxxx" \ | |
-H "Content-Type: application/json" \ | |
-d '{ "query": "query { listUsers { name } }" }' \ | |
https://app-id.appsync-api.us-east-1.amazonaws.com/graphql | |
# mutation with variables | |
curl \ |
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
defmodule TravelerWeb.SearchbarLive do | |
use TravelerWeb, :live_view | |
alias Phoenix.LiveView.JS | |
alias Traveler.Places | |
def mount(_params, _session, socket) do | |
socket = assign(socket, places: []) | |
{:ok, socket, layout: false} | |
end |
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
#!/usr/bin/env bash | |
DATABASE_URL="postgres://MyPostgresUser:MyPostgresPassword@192.168.0.1:5432/MyPostgresDB" | |
# `cut` is used to cut out the separators (:, @, /) that come matched with the groups. | |
DATABASE_USER=$(echo $DATABASE_URL | grep -oP "postgres://\K(.+?):" | cut -d: -f1) | |
DATABASE_PASSWORD=$(echo $DATABASE_URL | grep -oP "postgres://.*:\K(.+?)@" | cut -d@ -f1) | |
DATABASE_HOST=$(echo $DATABASE_URL | grep -oP "postgres://.*@\K(.+?):" | cut -d: -f1) | |
DATABASE_PORT=$(echo $DATABASE_URL | grep -oP "postgres://.*@.*:\K(\d+)/" | cut -d/ -f1) |
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
# Decompile | |
dtc -I dtb -O dts -o devicetree.dts /boot/dtb/<your_devicetree_file_name>.dtb | |
# Compile | |
dtc -I dts -O dtb devicetree.dts -o <your_devicetree_file_name>.dtb | |
# Merge with DTBO | |
fdtoverlay -i modified-base.dtb -o modified-full.dtb /boot/tegra194-p3668-all-p3509-0000-user-custom.dtbo | |
# DTS from fs |
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
—– BEGIN LICENSE —– | |
Mifeng User | |
Single User License | |
EA7E-1184812 | |
C0DAA9CD 6BE825B5 FF935692 1750523A | |
EDF59D3F A3BD6C96 F8D33866 3F1CCCEA | |
1C25BE4D 25B1C4CC 5110C20E 5246CC42 | |
D232C83B C99CCC42 0E32890C B6CBF018 | |
B1D4C178 2F9DDB16 ABAA74E5 95304BEF | |
9D0CCFA9 8AF8F8E2 1E0A955E 4771A576 |
NewerOlder