Tumgik
machine-readable · 10 years
Text
Time/Date Stamps in a Batch File
Ever need time or date stamps in a batch file?
@echo off For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set mydate=%%c-%%a-%%b) For /f "tokens=1-2 delims=/:" %%a in ('time /t') do (set mytime=%%a%%b) For /f "tokens=1-2 delims=/:" %%a in ("%TIME%") do (set mytime=%%a%%b) echo %mydate%_%mytime%
I think that should do it. I needed this to include time stamps with a log file that was automatically being generated.
1 note · View note
machine-readable · 10 years
Link
A collection of random tips for Amazon Web Services (AWS) that I wish I'd been told a few years ago, based on what I've learned by building and deploying various applications on AWS.
These are some pretty solid tips. A little extreme in some cases, but it makes me think how far automation could, and maybe should, go.
0 notes
machine-readable · 10 years
Text
I know exactly how that feels.
The code refactoring trap
by Juan and others
214 notes · View notes
machine-readable · 10 years
Link
Learn how to use Gradle’s rich set of APIs and Groovy-based Domain Specific Language to customize build software that actually conforms to your product. By using the techniques in this book, you’ll be able to write domain-specific builds that support every other line of code your team creates.
Read it online.
0 notes
machine-readable · 10 years
Link
Structure and Interpretation of Computer Programs (SICP) is a textbook aiming to teach the principles of computer programming, such as abstraction in programming, metalinguistic abstraction, recursion, interpreters, and modular programming. It is widely considered a classic text in computer science. It was first published in 1984 by MIT Press and written by Massachusetts Institute of Technology (MIT) professors Harold Abelson and Gerald Jay Sussman, with Julie Sussman... Before SICP, the introductory courses were almost always filled with learning the details of some programming language, while the SICP focused on finding general patterns from specific problems and building software tools that embody each pattern.
Read it online.
0 notes
machine-readable · 10 years
Link
The truth about Groovy. A quick reference for coding in Groovy.
The user guide seems to be pretty decent altogether.
0 notes
machine-readable · 10 years
Link
This may not be the best way to select css colors but it works great for me.
0 notes
machine-readable · 10 years
Link
The Unix shell is often overlooked by software developers more familiar with higher level languages. This is unfortunate because the shell can be one of the most important parts of a developer’s toolkit. From the one-off grep search or sed replacement in your source tree to a more formal script for deploying or backing up an entire application complete with options and error handling, the shell can be a huge time saver.
To help shed light on the power and subtlety that is the Unix shell, I’d like to take a deep dive into just one of its many features: the humble if statement.
6 notes · View notes
machine-readable · 10 years
Link
A beginner's guide to Java code protection, showing where obfuscation falls short and what are the alternative/complementary solutions.
This is a really good write-up about protecting Java code, with some helpful comparisons to c++. Includes options for obfuscating your source.
0 notes
machine-readable · 10 years
Text
Links of Interest, circa July 21-27, posted much later
Reading material
A few posts that might be worth reading:
Michael Church wrote about IDE Culture vs. Unix Philosophy awhile back and I recently stumbled onto his article. I totally get where he's coming from.
What every web developer must know about url encodings
Linux system mining with python
Useful code
Some code I found useful:
These chmod tricks from Chris Gilligan came in handy.
Hardening an Ubuntu server
The basics
More from andrewault.net
Tips straight from the Ubuntu Security Team
Update from the Security Team
0 notes
machine-readable · 10 years
Link
Dennis MacAlistair Ritchie was an American computer scientist who "helped shape the digital era." He created the C programming language and, with long-time colleague Ken Thompson, the Unix operating system.
0 notes
machine-readable · 10 years
Text
Setting Up Local DNS Server on Ubuntu
Via mixeduperic
Record the steps:
Set a static IP
sudo apt-get install bind9 dnsutils bind9-doc
Configure Bind
forwarding addresses
local configuration file
local Foward Zone file
local Reverse Zone file
Start the bind9 server: sudo /etc/init.d/bind9 start
Test it locally (on the server)
Test it on a client machine (set /etc/resolv.conf for temp check)
0 notes
machine-readable · 10 years
Link
The XPS 13 Linux® laptop, developer edition makes sacrificing power for extreme portability a thing of the past with an ultrathin 13" design and powerful Intel® Core™ processors. Get yours today.
Yes, please.
Not really time for a new laptop but hopefully there will be a chance in 2014 to upgrade.
0 notes
machine-readable · 10 years
Link
Just run
sudo -u user -s
That's how. Also,
How to set chmod for a folder and all of its subfolders and files in Linux Ubuntu Terminal?
Ever need to set permissions recursively on a directory? You could just make do everything all-in-one with something like:
chmod -R 644 path/to/blah
That might cover all the files fine with -rw-r--r--. But don't do that, what about any subdirectories? Use find by type:
find path/to/blah -type d -exec chmod 755 {} \; find path/to/blah -type f -exec chmod 644 {} \;
That should do it.
4 notes · View notes
machine-readable · 10 years
Link
This is right in-line with the semantic versioning post recently made on machine-readable ...
A methodology for building modern, scalable, maintainable software-as-a-service apps.
Who should read this document?
Any developer building applications which run as a service. Ops engineers who deploy or manage such applications.
0 notes
machine-readable · 10 years
Text
Installing git from source
Download the source tar
untar it
run make prefix=/usr/local all
run sudo make prefix=/usr/local install
For some reason, the Ubuntu default version of git is still lagging at 1.7.9.*.
Dependencies
sudo apt-get install libcurl4-gnutls-dev libexpat1-dev gettext libz-dev libssl-dev build-essential
Download the tar of the desired version from the project download page
Here's some code to make it even easier.
0 notes
machine-readable · 10 years
Link
Internet history. Interesting stuff. NSFW.
1 note · View note