Hi all .
In this post, I'll describe setting up a C++ environment using Sublime Text 3 and the GNU compiler. This will allow you to write code in C++ and be able to build and run it all from within the Sublime Text 3 editor.
Things you will need:
Sublime Text 3 - https://www.sublimetext.com/
MinGW -w64 - https://sourceforge.net/projects/mingw-w64/
Build system file - https://gist.githubusercontent.com/sagebind/9039773048a3900fa49a/raw/e465947afb43948b471f739992ce303a92befbf8/MinGW-w64.sublime-build
About 10-15 minutes to complete setup and test. Note: You will probably need to install under an admin account to make sure everything installs correctly.
Steps:
1. Install Sublime Text 3 onto your system.
2. Install MinGW -w64
(Note the location/folder it gets installed to)
3. Set the path variable for MinGW
Note: If you need help at this step, please see the following link and check the 'Environment Settings' section: http://www.mingw.org/wiki/Getting_Started
4. Copy the following build file and place it within Sublime Text's package folder:
https://gist.githubusercontent.com/sagebind/9039773048a3900fa49a/raw/e465947afb43948b471f739992ce303a92befbf8/MinGW-w64.sublime-build
Once the above file has been copied to a file and saved within the package folder, you can should be able to build code under Sublime Text.
Write your code in Sublime and then test by going to Tools > Build.
Enjoy!
Thursday, May 24, 2018
Monday, April 30, 2018
Impossible To Tell if Laptop Was Hacked Article
Found this interesting article today and thought that I would share:
https://theintercept.com/2018/04/28/computer-malware-tampering/
https://theintercept.com/2018/04/28/computer-malware-tampering/
Friday, March 16, 2018
PowerPoint Saving Tricks
Just a quick 2 "tricks" when working with PowerPoint files.
1. When saving, instead of doing the usual save as .ppt...instead save your slides as a .pps. When you open this, it will go directly into presentation mode.
2. When you're going to be doing a presentation from another computer, consider saving your slides to .pdf format. This will ensure you don't run into any weird software mishaps if the computer you're presenting on has a different version of PowerPoint than the one you created the slides on.
1. When saving, instead of doing the usual save as .ppt...instead save your slides as a .pps. When you open this, it will go directly into presentation mode.
2. When you're going to be doing a presentation from another computer, consider saving your slides to .pdf format. This will ensure you don't run into any weird software mishaps if the computer you're presenting on has a different version of PowerPoint than the one you created the slides on.
Finding Inactive Computers With Powershell
Here is a quick script I ran at work yesterday to find inactive computers in our active directory. It checks the last time a system was logged on for a given amount of days specified by the user in the script.
Here's the code:
# Michael L. Kelley Jr.
# March 15, 2017
# InactiveComputers.ps1
# A script to find inactive computers via days not logged on
$DaysInactive = 90
$time = (Get-Date).Adddays(-($DaysInactive))
Get-ADComputer -Filter {lastlogontimestamp -lt $time} -Properties Name.OperatingSystem , lastlogintimestamp| Select Name.OperatingSystem,
@{N='lastlogontimestamp'; E={[DateTime]::FromFileTime($_. lastlogontimestamp)}}
Read-Host -Prompt "Press enter to exit"
Here's the code:
# Michael L. Kelley Jr.
# March 15, 2017
# InactiveComputers.ps1
# A script to find inactive computers via days not logged on
$DaysInactive = 90
$time = (Get-Date).Adddays(-($DaysInactive))
Get-ADComputer -Filter {lastlogontimestamp -lt $time} -Properties Name.OperatingSystem , lastlogintimestamp| Select Name.OperatingSystem,
@{N='lastlogontimestamp'; E={[DateTime]::FromFileTime($_. lastlogontimestamp)}}
Read-Host -Prompt "Press enter to exit"
Running this script on your AD server, will check for computers that haven't been logged on for 90 days or more. It will return the AD computer name, operating system, and time last logged on. Perfect for cleaning up active directory for systems that are no longer around. Just change the $DaysInactive variable as needed.
Subscribe to:
Posts (Atom)