Omen dev

From Wiki2
Revision as of 21:56, 8 August 2018 by Tim (talk | contribs)

omen WSL wsl development env

file managers

nemo

sudo nemo
//open in code-insiders opens a superuser code-insiders

nautilus

export DISPLAY=localhost:0.0
nautilus .

code-insiders

got code-insiders to work inside bash using

//start xterm
sudo services dbus start
code-insiders info.php --verbose
//for system files that need root access start with
sudo code-insiders --user-data-dir="~/.vscode-root"

to track down errors

references

docker

https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=0ahUKEwiDrO6brOXbAhWrrFkKHRoDChsQFggpMAA&url=https%3A%2F%2Fblogs.msdn.microsoft.com%2Fcommandline%2F2017%2F10%2F27%2Frunning-node-js-on-wsl-from-visual-studio-code%2F&usg=AOvVaw124mrFIt0TlYoyY2rtQwtT


npm

tips

sudo -i sets you as superuser

systemctl doesn't work use

/etc/init.d/php7.0-fpm restart 

or

service nginx restart

when editng files you need to set permissions

chmod 644 info.php
Numeric  Readable    Explanation
0        ---         No access.
1        --x         Execute access.*
2        -w-         Write access.**
3        -wx         Write and execute access.***
4        r--         Read access.
5        r-x         Read and execute access.
6        rw-         Read and write access.
7        rwx         Read, write and execute access.

startup

sudo service nginx start
sudo service mysql start
sudo service php7.0-fpm start
sudo service dbus start

MySQL

mysqldump -uroot -pnji9ol --all-databases > dump.sql
mysqldump -uroot -pthepass --opt geniot > geniot.sql

or mo better with /root.my.cnf no user password needed

[mysqldump]
user=root
password=dfff

then run

bash dump.sh

which is

#!/bin/sh
mysqldump --all-databases > dump.sql

then get the data from the remote server

sftp root@sitebuilt.net:/root/data/*.sql /data/MySQL

do the /home/tim/.my.cnf thing on omen

[mysqldump]
user=root
password=nff
[mysql]
user=root
password=gg

then

MySQL < dump.sql

manage data with

MySQL-workbench