Skip to content

Instantly share code, notes, and snippets.

View Kernix13's full-sized avatar
💭
Still looking for a job - but losing hope

Jim Kernicky Kernix13

💭
Still looking for a job - but losing hope
View GitHub Profile
@Kernix13
Kernix13 / recent-posts-custom-query.php
Last active July 26, 2023 15:18
WordPress Recent Posts Custom Query
<!-- Add to a plugin or in front-page.php for a custom theme -->
<aside class="bgcolor4">
<div class="container">
<h3 class="custom-title"><?php esc_html_e('Latest Articles ', 'tower') ?></h3>
<div class="row">
<?php
$query = new WP_Query( [
'post__not_in' => get_option( 'sticky_posts'),
'post_type' => 'post',
@Kernix13
Kernix13 / ssh.md
Created September 19, 2022 12:48 — forked from bradtraversy/ssh.md
SSH & DevOps Crash Course Snippets

SSH Cheat Sheet

This sheet goes along with this SSH YouTube tutorial

Login via SSH with password (LOCAL SERVER)

$ ssh brad@192.168.1.29

Create folder, file, install Apache (Just messing around)

$ mkdir test

$ cd test

@Kernix13
Kernix13 / SplitSortFilterStr.js
Last active September 16, 2022 21:04
JavaScript function to split, sort, and filter out repeats from a string
// Function to sort words then strip out repeats
// Used to get unique keywords from different web languages/tools I've used to get ideas for blog posts. I tend to have a lot of repeats...
const commaSeparated = "split, sort, and, filter, strings, separated, by, commas, with, no, repeats, repeats, repeats";
const spaceSeparated = "split sort and filter strings separated by spaces with no repeats repeats repeats";
let commaWords = [];
let spaceWords = [];
function splitStrings(str, separator, output) {
@Kernix13
Kernix13 / hamburgerMenu.css
Last active November 22, 2022 13:30
Mobile first responsive hamburger menu
*, *::before, *::after {
box-sizing: border-box;
}
body {
padding: 0;
margin: 0;
}
header {
@Kernix13
Kernix13 / BlogTitleUrl.js
Created September 15, 2022 15:23
Convert blog title to URL slug (my first gist)
const blogTitle = "How to create a GitHub Gist";
const urlSlug = blogTitle.toLowerCase().split(" ").filter(word => word !== "").join("-");
@Kernix13
Kernix13 / terminal-commands.md
Created September 15, 2022 01:23 — forked from bradtraversy/terminal-commands.md
Common Terminal Commands

Common Terminal Commands

Key Commands & Navigation

Before we look at some common commands, I just want to note a few keyboard commands that are very helpful:

  • Up Arrow: Will show your last command
  • Down Arrow: Will show your next command
  • Tab: Will auto-complete your command
  • Ctrl + L: Will clear the screen