Skip to content

Instantly share code, notes, and snippets.

View Theaxiom's full-sized avatar
🙏
Namaste

Jeshua Ben Joseph Theaxiom

🙏
Namaste
View GitHub Profile
@Theaxiom
Theaxiom / yn.php
Created March 20, 2017 02:24
PHP yes/no function
/**
* @param $bool
* @return string
*/
function yn($bool)
{
return ($bool)?'Yes':'No';
}
@Theaxiom
Theaxiom / ReleasesController.php
Created April 11, 2017 16:15
Extending view method
<?php
namespace App\Controller\Api;
/**
* Releases Controller
*
* @property \App\Model\Table\ReleasesTable $Releases
*/
class ReleasesController extends ApiAppController
{
@Theaxiom
Theaxiom / ApiAppController.php
Created April 11, 2017 16:16
Remapping new CRUD actions
<?php
namespace App\Controller\Api;
use Cake\Controller\Controller;
class ApiAppController extends Controller
{
use \Crud\Controller\ControllerTrait;
@Theaxiom
Theaxiom / AppController.php
Created April 12, 2017 23:31
How to automatically protect actions
<?php
/**
* @param null $user
* @return bool
*/
public function isAuthorized($user = null)
{
// Admin can access every action
if ($user && isset($user['is_admin']) && $user['is_admin']) {
$this->Auth->allow();

Hacknet Speedrun Any% Notes by Pastillage

Update History:

  • v1.2.0 update new CSEC Route, this should be the fastest route now.
  • v1.3.0 update Found a way to skip Naix's hack
  • v1.3.5 Route updates to skip getting eosdevicescanner and Faster Sequencer
  • v1.4.0 2 Optimisations to the route, Route changes have been marked by [Route Change]
@Theaxiom
Theaxiom / mysubaru.py
Created January 30, 2020 20:10 — forked from nbonfire/mysubaru.py
MySubaru python samples
import requests, json
from subarucreds import username,password,pin # just a "subarucreds.py" that has some variables i didn't want to share
import datetime
#login
s=requests.Session()
loginr=s.post('https://www.mysubaru.com/login', data = {'username':username,'password':password})
#should return a response 200
#Where's my subaru?
@Theaxiom
Theaxiom / fix-commits.sh
Created November 5, 2021 02:55
Fix all commits in current branch with correct author and committer information
#!/bin/sh
git filter-branch -f --env-filter '
an="$GIT_AUTHOR_NAME"
am="$GIT_AUTHOR_EMAIL"
cn="$GIT_COMMITTER_NAME"
cm="$GIT_COMMITTER_EMAIL"
if [ "$GIT_COMMITTER_EMAIL" = "user@wrongemail.com" ]