Install, build and debug a react native app in WSL2 (Windows Subsystem for Linux) and Ubuntu.
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
from zipfile import ZipFile | |
import os | |
import base64 | |
import textwrap | |
div = "---" | |
action = "dump" | |
def get_all_file_paths(directory): | |
file_paths = [] |
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
curl -H 'Authorization: token abcabctodacriancavailereescrever' -H 'Accept: application/vnd.github.VERSION.patch' -L https://api.github.com/repos/google/protobuf/pulls/666 |
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
# mean_train_features <- colMeans(data_training[, 1:8]) | |
# sd_train_features <- apply(data_training[, 1:8], 2, sd) | |
# mean_train_features | |
# sd_train_features | |
# data_training[, 1:8] <- sweep(data_training[, 1:8], 2, mean_train_features, "-") | |
# data_training[, 1:8] <- sweep(data_training[, 1:8], 2, sd_train_features, "/") | |
# data_validation[, 1:8] <- sweep(data_validation[, 1:8], 2, mean_train_features, "-") |
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
install.packages("Rcpp", dependencies=TRUE, INSTALL_opts = c('--no-lock')) | |
install.packages("languageserver", dependencies=TRUE, INSTALL_opts = c('--no-lock')) |
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
"Airline Cruise Lines" | |
"Advertising Services" | |
"CBD Oil" | |
"Drop shipping Suppliers" | |
"Adult" | |
"Collection Agencies" | |
"Call Center B2B" | |
"Product or Tangible Items" | |
"Credit Repair" | |
"Firearms" |
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
(ENV['RUBY_VERSION'].gsub(/\W\w/, '').chars - 98.chr.chars).join.capitalize |
Direct installation of MySQL 8.x will not work on WSL, even after your have selected 8.x as the default install candidate. It has problem starting the server.
Steps below should work (tried out on few WSL instances):
1- Remove MySQL 8.x:
sudo apt-get purge mysql-server mysql-client
sudo apt-get -y autoremove
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
# Install MySQL | |
mysql_config_file="/etc/mysql/my.cnf" | |
echo "mysql-server mysql-server/root_password password secret" | sudo debconf-set-selections | |
echo "mysql-server mysql-server/root_password_again password secret" | sudo debconf-set-selections | |
apt-get -y install mysql-client mysql-server | |
sed -i "s/bind-address\s*=\s*127.0.0.1/bind-address = 0.0.0.0/" ${mysql_config_file} | |
usermod -d /var/lib/mysql/ mysql |
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
Windows Registry Editor Version 5.00 | |
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout] | |
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00 |