美文网首页
Section1.3 Examples

Section1.3 Examples

作者: BetaGrey | 来源:发表于2018-02-10 13:08 被阅读0次

Examples

Some Dependencies problems

#list all the packages that gtkmm depends and require:
pacman -Qi open-vm-tools
#or
pacman -Si open-vm-tools

#Cannot change display setting:
sudo pacman -S gnome-control-center

#Cannot paste from VMWare host:
sudo pacman -S gtkmm
sudo pacman -S open-vm-tools

VMWare Host share folder with Guest

#to check
vmware-hgfsclient

#mkdir
mkdir -p /home/grey/Shared

#mount
sudo vmhgfs-fuse -o allow_other -o auto_unmount -o uid=1000 -o gid=1000 .host:/VMShared /home/grey/Shared
//a automate C program for above purpose
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>

int main()
{
    //check the hgfs service
    if (system("vmware-hgfsclient")==-1) {
       printf("Please turn on VMWare Shared Folder, then try again\n");
       return 0;
    }

    //get the current user's name
    char path[60];
    sprintf(path,"/home/%s/Shared",getenv("USER"));

    //if director /home/userName/Shared doesn't exit, make one
    if (access(path,0)!=0) {
        char mkSharedir[100];
        sprintf(mkSharedir,"mkdir -p %s",path);
        system(mkSharedir);
    }

    //do the mount(connet the maked directory with the VMware shared folder VMShared)
    char finalCmd[200];
    sprintf(finalCmd,"sudo vmhgfs-fuse -o allow_other -o auto_unmount -o uid=1000 -o gid=1000 .host:/VMShared %s",path);
    system(finalCmd);
}

Majaro ssh

Open ssh in ArchLinux

#Linux默认安装openssh-server

#start sshd
systemctl start sshd

#check locally
ssh grey@localhost

#when local login in, means success

#in Mac Terminal
ssh grey@162.105.147.126

#in Linux Terminal
ssh grey@162.105.147.126

#finally test ip
ifconfig
#another method

#start the service
service sshd start
service sshd status

#stop the service
service sshd start

In windows,借助putty

putty.png

LaTex Software

Latex01.png

Install ibus

sudo pacman -S ibus
sudo pacman -S ibus-libpinyin
ibus-setup
#add chinese
#in region&language, add chinese

cannot copy

#run this one
pacman -S gtkmm

gedit /etc/xdg/autostart/vmware-user.desktop
[Desktop Entry]
Type=Application
Encoding=UTF-8
Exec=/usr/bin/vmware-user-suid-wrapper
Name=VMware User Agent
# KDE bug 190522: KDE does not autostart items with NoDisplay=true...
# NoDisplay=true
X-KDE-autostart-phase=1

database

#install mariaDB
yaourt mariaDB

#install MySQL Workbench
yaourt workbench

config database

相关文章

网友评论

      本文标题:Section1.3 Examples

      本文链接:https://www.haomeiwen.com/subject/ndbctftx.html