Skip to content

Instantly share code, notes, and snippets.

View Skalnark's full-sized avatar
🥄
There is no spoon

Dárcio Basílio Skalnark

🥄
There is no spoon
  • Brazil
View GitHub Profile
@Skalnark
Skalnark / eduroam.sh
Last active September 14, 2022 17:44 — forked from AntonFriberg/eduroam.sh
Conectar a eduroam na Universidade Federal da Paraíba usando NetworkManager
# !/bin/bash
nmcli con add \
type wifi \
con-name "eduroam" \
ssid "eduroam" \
wifi-sec.key-mgmt "wpa-eap" \
802-1x.identity "seu usuario do sigaa@ufpb.br"
802-1x.password "sua senha do sigaa" \
802-1x.system-ca-certs "yes" \
802-1x.domain-suffix-match "ufpb.br" \

Comandos de usuário

  • r = ler; w = escrever; x = executar
  • chmod:
    • chmod +x filename

    Dá permissão de execução para todos os usuários Os outros argumentos podem ser +w e +r

    • chmod u=rwx,g=rwx,o=rwx filename

    Dá as permissões rwx para usuário, grupo e outros

    • chmod 777 filename

    Dá as permissões 7 (rwx) para usuário, grupo e outros

Comandos

  • echo

exibe uma linha de texto

  • clear

limpa o terminal

  • ls (list)

exibe o conteúdo de uma pasta

  • ls -l

exibe o conteúdo de uma pasta em formato de lista

@Skalnark
Skalnark / Run protondb on Arch linux
Last active January 15, 2022 16:44
Steam on arch linux
# Enable multilib
$ sudo vim /etc/pacman.conf
# Add/uncomment the following to the file:
[multilib]
Include = /etc/pacman.d/mirrorlist
# Update the package database and install Steam
$ sudo pacman -Sy
$ sudo pacman -S steam
@Skalnark
Skalnark / Sort.cs
Created February 19, 2020 01:44
Sorting
using System;
class Sort {
static void InsertionSort(int[] arr)
{
int n = arr.Length;
for (int i = 1; i < n; ++i)
{
int key = arr[i];
int j = i - 1;
#### define o compilador
CPPC = g++
#############################
#### opcoes de compilacao e includes
CCOPT = -O3 -fPIC -fexceptions -DNDEBUG -DIL_STD -std=c++11
CONCERTINCDIR = $(CONCERTDIR)/include
CPLEXINCDIR = $(CPLEXDIR)/include
#############################