Skip to content

Instantly share code, notes, and snippets.

View TurBoss's full-sized avatar

turboss TurBoss

  • Spain
  • 06:19 (UTC +02:00)
View GitHub Profile
# ***** BEGIN GPL LICENSE BLOCK *****
#
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
The following are command line commands for backing up /dev/sda1 in the same manner
that "redo backup and restore" uses. Note that the MD5 of the partition files will
not be the same because gzip stores info about the current time
(http://superuser.com/questions/617934/):
#mount network drive
mount.cifs '//host.example.com/fab/temp' /mnt/backup -o username=myuser,password=mypass
#save backup list (sda1 in our case)
echo sda1 > /mnt/backup/20141009.backup
@TurBoss
TurBoss / grup_labels.lua
Created February 2, 2016 02:54
Group_labels by [LCC]Pako
function widget:GetInfo()
return {
name = "Group Label - new",
desc = "Displays label on units in a group",
author = "gunblob, Pako",
date = "June 12, 2008, 29.01.2016",
license = "GNU GPL, v2 or later",
layer = 0,
enabled = true
}
#!/bin/bash
#branches develop release
BRANCH="develop"
date=$(date)
OUTPUT=$(python /home/spring/scripts/upq.py)
@TurBoss
TurBoss / dll.py
Created June 13, 2016 05:21
run dll cffi
import os
from cffi import FFI
ffi = FFI()
ffi.cdef(
"""
bool IsUserAnAdmin(void);
"""
)
@TurBoss
TurBoss / Cloudbox
Created July 23, 2016 15:26 — forked from sleimanzublidi/Cloudbox
Cloudbox SSH
t's quite easy, no disassembling required.
1. Enable SFTP in the web interface
2. Open a SFTP connection to the box using your admin account
3. Change directory to the Admin: cd Admin
4. Create a link for default.runlevel file: symlink /etc/initng/runlevel/default.runlevel default.runlevel
5. Create a link for shadow file: symlink /etc/shadow shadow
6. Create a link for unicorn.sharing.ssh.conf file: symlink /etc/unicorn/unicorn_conf/unicorn.sharing.ssh.conf unicorn.sharing.ssh.conf
7. You can close SFTP connection now
8. Open the web file manager in your browser and navigate to the Admin folder
/********************************************************************
* Description: galvo9kins.c
* Kinematics for 2 axis galvanometer scanner
* Derived from:
*
* Author: Jozsef Papp / hg5bsd
* License: coding and fitting it into EMC2 from our part is GPL alike
*
* System: realtime Linux, EMC2
* Copyright (c) 2010 All rights reserved.
#!/bin/bash
#branches develop release
BRANCH="develop"
date=$(date)
OUTPUT=$(python /home/spring/scripts/upq.py)
VERSION=$(echo "$OUTPUT" | cut -d' ' -f1)
@TurBoss
TurBoss / Heiden.py
Created December 21, 2016 16:29
A Heidenhain 530 postprocesor for heekscnc blendercam and freecad
################################################################################
# heiden.py
#
# Post for heidenhain
#
# TurBoss 01/07/2016
#
################################################################################
from . import nc
@TurBoss
TurBoss / fadal.py
Created December 21, 2016 16:30
A fadal postprocesor for heekscnc blendercam and freecad
################################################################################
# fadal.py
#
# Fadal ISO NC code creator
#
# TurBoss, 19/06/2016
#
################################################################################
import math