#Unix Toolbox
This document is a collection of Unix/Linux/BSD commands and tasks which are useful for IT work or for advanced users. This is a practical guide with concise explanations, however the reader is supposed to know what s/he is doing.
##Unix Toolbox revision 14.4
The latest version of this document can be found at http://cb.vu/unixtoolbox.xhtml. Replace .xhtml on the link with .pdf for the PDF version and with .book.pdf for the booklet version. On a duplex printer the booklet will create a small book ready to bind. This XHTML page can be converted into a nice PDF document with a CSS3 compliant application (see the script example). See also the about page.
Error reports and comments are m
Error reports and comments are m
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
// Draws a texture in 3D space with pro parameters... | |
void DrawTexturePro3D(Texture2D texture, Rectangle sourceRec, Rectangle destRec, Vector3 origin, float rotation, float posZ, Color tint) | |
{ | |
// Check if texture is valid | |
if (texture.id > 0) | |
{ | |
float width = (float)texture.width; | |
float height = (float)texture.height; | |
bool flipX = false; |
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
#include <stddef.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include "getopt.h" | |
char *optarg; | |
int optind=1, opterr=1, optopt, __optpos, optreset=0; | |
#define optpos __optpos |
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
-- Written by Rabia Alhaffar in June 14, 2021 | |
-- Simple script to detect some operating systems and CPU architecture via Lua! ;) | |
-- Updated: June 14, 2021 | |
-- Also, I would thank NickWilde263 and Nameless on GitHub for their suggestions! <3 | |
-- https://github.com/NickWilde263 | |
-- https://github.com/truemedian | |
local sys = { | |
arch = "UNKNOWN", |
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
public static class Rectangle extends Raylib.Rectangle { | |
public Rectangle() { | |
super(); | |
} | |
public Rectangle(float x, float y, float width, float height) { | |
x(x); | |
y(y); | |
width(width); | |
height(height); | |
} |
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
-- Written by Rabia Alhaffar in 26/September/2020 | |
-- Simple way to get biggest and smallest number from table in Lua | |
local function bignum(t) | |
local _ = -math.huge | |
for i in ipairs(t) do | |
if (t[i] >= _) then | |
_ = t[i] | |
end | |
end | |
return _ |
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
-- Written by Rabia Alhaffar in 27/September/2020 | |
-- Even or Odd example | |
local function even(a) | |
if ((a % 2) == 0) then | |
return true | |
else | |
return false | |
end | |
end |
NewerOlder