Skip to content

Instantly share code, notes, and snippets.

View noynaert's full-sized avatar

noynaert

  • Missouri Western State University
  • St. Joseph, Missouri
View GitHub Profile
@noynaert
noynaert / csc346Spring2016
Last active April 22, 2016 03:21
CSC346 course files for Json and XML
This Gist is for miscellaneous files from CSC346 at Missouri Western State University.
@noynaert
noynaert / CSC445Spring2016
Created April 14, 2016 22:25
CSC445Spring2016
Miscellaneous files
@noynaert
noynaert / CSC346 xmlInGo2.go
Last active April 26, 2016 17:10
marshalling and unmarshalling XML
// From https://golang.org/src/encoding/xml/example_test.go
// Copyright 2012 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package main
import (
"encoding/xml"
"fmt"
"os"
package main
import (
"fmt"
"net/url"
"log"
"net/http"
"io/ioutil"
"encoding/xml"
)
@noynaert
noynaert / csc346XMLtoJSON.go
Created April 28, 2016 19:53
Converting XML data to JSON
package main
import (
"fmt"
"net/url"
"encoding/xml"
"net/http"
"log"
"io/ioutil"
"encoding/json"
@noynaert
noynaert / CSC346xmlToJsonWithASingleStruct.go
Created May 4, 2016 05:09
This is an improved method of moving data from XML to JSON (or JSON to XML). Only one struct is needed, and you don't need to export to another struct. See the opening comment
package main
//
// This is a bit of an improvement over the code I did in class.
// There are two changes that might make your life easier
// 1) You can just use "string" instead of the XML data type.
// 2) You can include both the xml and json in the same backtick.
// All you have to do is put in a comma, like this:
// TypeOfError string `xml:"type,json:"type"
//
// The really nice thing about 2) is that you can use just one
@noynaert
noynaert / Laravel on Linux.md
Last active July 6, 2024 04:12
Installing Laravel on Linux.

Installing Laravel on Linux

Note: This document is not finished.

Written for Laravel 2.3 and PHP 7

This is written for Ubuntu, LinuxMint, and oter debian derivatives that use apt or apt-get. I have tested it on Ubuntu 16.04 LTS. Also, this installation may not be the minimum. In particular, some of the php files May not be absolutely necessary, especially if you are not running nginx and valet.

I have this guide on Fedora using "dnf" instead of apt should work in most places. A few of the PHP bundles are a bit differentently, but It still worked. The Fedora packages seem to be more inclusive, so all of the important PHP components seemed to be loaded.

Homestead

Homestead is a useful tool. but it can be overwhelming at first if you are trying to learn both Laravel and Homestead.

@noynaert
noynaert / gitForStudents.md
Last active January 21, 2018 23:04
A basic introduction to GIT for students.

GIT for School

This is an introduction to git. Frankly, git can be confusing. Relevant XKCD (Be sure to check the "mouseover.)

Benefits for Students

I think there are at least four reasons for CSC and ACT students to learn git.

  1. It is a skill employers like to see.
  2. It makes development easier.
  • Students often comment out large blocks of code. Eventually there are more comments
@noynaert
noynaert / basicLinux.md
Created January 23, 2017 16:49
Getting your linux system set up, basic concepts, and bash commands.

#Setting up your system, and basic bash Linux is a form of Unix. This document will focus more on the "bash shell."

Most modern Linux distributions have a "desktop" interface that looks something like Microsoft Windows. Some of these desktops, like Cinnamon and Mate look vaguely like Windows 7. Others like Unity look more like Windows 8 or Windows 10.

I will be focusing mostly on the "bash shell." The shell is basically a command line interface. It uses the keyboard. You bring it up in a "terminal window." It is often called "term." Term is only mildly aquainted with the mouse so most interactions happen on the keyboard.

The shell has grown over the years. Now most modern systems use the "Bash Shell." Macintosh also uses the Bash shell. Microsoft has announced that it will be releasing the Bash shell for windows as well. It is worth learning as much as possible about the bash shell if you are in IT.

@noynaert
noynaert / linuxAndUnixFileNamed.md
Last active January 27, 2017 16:57
Linux and Unix file names, including command line operations

#Linux and Unix files and directories at the command line

The same rules apply to file names and directory names, but conventions vary a bit. For example, file names often have extensions, but directory names seldom do.

File Names

File names that start with a period . are "hidden" files

A good set of guidelines is at https://www.cyberciti.biz/faq/linuxunix-rules-for-naming-file-and-directory-names/

Summary of the key points: