This shows up as "^M" in some editors, and can cause some scripts to fail.
To fix it, install the package "dos2unix". Available in at the minimum RedHat and Ubuntu based distros.
My online tech scrapbook where I keep my notes in case I need to look them up later
Tuesday, August 6, 2013
Thursday, August 1, 2013
Android Private Libraries
In the Eclipse ADT, this is libraries that are placed in the "libs" folder, they are automatically placed on the classpath as "Android Private Libraries".
However, when removing it, the ADT removes the library but flags it as an error as it is missing. A restart needed to be performed before the project compiles properly.
However, when removing it, the ADT removes the library but flags it as an error as it is missing. A restart needed to be performed before the project compiles properly.
Android Include Library in APK
In order for library JAR files to be included in the APK, it is necessary to go the "Build Path" and check "Android Private Libraries" in "Order and Export".
References:
References:
Android Library References
To make one project depend on another, add into project.properties as follows:
android.library.reference.1=../LibraryOne
android.library.reference.2=../LibraryTwo
|
Friday, July 12, 2013
Article About Data Scientist Jobs
Talks about what the requirements are for someone who aspires to gets hired as one.
Link: http://gigaom.com/2013/04/16/how-to-hire-data-scientists-and-get-hired-as-one/
Link: http://gigaom.com/2013/04/16/how-to-hire-data-scientists-and-get-hired-as-one/
Tuesday, July 9, 2013
Android Themes Remove Action/Title Bar
Some people do this by using themes that don't have title or action bars, but this might be in conflict with existing theming requirements. This method is also difficult to apply to multiple SDK levels at the same time, due to inconsistent theme availability.
The best solution so far is to add customizations within each style as described in these answers:
Android Icon Sizes
Current recommended launcher icon sizes in Android:
- 48 x 48 (mdpi)
- 72 x 72 (hdpi)
- 96 x 96 (xhdpi)
- 144 x 144 (xxhdpi)
There is also 36 x 36 for ldpi but the OS is able to resize that nicely from the better quality ones.
Wednesday, June 12, 2013
Monday, June 10, 2013
Big Data is About Speed Instead of Just Size
Article: http://www.guardian.co.uk/news/datablog/2013/may/20/big-data-critics-overlooked-speed-not-size
The main point of the article provides an insightful reminder for us not to be fixation with just the volume aspect of big data. There are many cases characterized by a high-velocity stream of data that needs to be processed and acted on immediately.
The main point of the article provides an insightful reminder for us not to be fixation with just the volume aspect of big data. There are many cases characterized by a high-velocity stream of data that needs to be processed and acted on immediately.
Google Launches "Mobile Backend as a Service"
Google launches "Mobile Backend as a Service" starter kit. It's called "Mobile Backend Starter" and runs on top of Google App Engine.
It's mainly a client-to-client networking and communications stack. It supports storage of state data on the server side and also Google Authentication. However, no customized server logic or extensions are supported.
References:
It's mainly a client-to-client networking and communications stack. It supports storage of state data on the server side and also Google Authentication. However, no customized server logic or extensions are supported.
References:
Wednesday, May 29, 2013
Application Management for AWS
Currently, the following application management frameworks are available for AWS (excludes third party solutions):
- AWS Elastic Beanstalk
- AWS OpsWorks
- AWS CloudFormation
Details can be found here: https://aws.amazon.com/application-management/
Something they didn't mention in the above web-page is that OpsWorks is a technology acquired in an acquisition, and does not integrate into all of AWS's services yet, the most important being ELB (OpsWorks uses HAProxy). Leaving CloudFormation as the framework of choice if this is an issue.
Forum post about this: https://forums.aws.amazon.com/message.jspa?messageID=426226
On the other hand, the downside of CloudFormation is the lack of automated failover.
On the other hand, the downside of CloudFormation is the lack of automated failover.
Sunday, April 7, 2013
BASH IO Redirection
In bash, by default, only stdout gets redirected to a file when you use the ">" operator.
To redirect stderr to a file, use the "2>" operator.
To redirect both, use "&>"
Reference:http://www.cyberciti.biz/faq/redirecting-stderr-to-stdout/
To redirect stderr to a file, use the "2>" operator.
To redirect both, use "&>"
Reference:http://www.cyberciti.biz/faq/redirecting-stderr-to-stdout/
Git Undo Staging a File for Commit
If a file has already been staged for commit i.e. via the "git add" command, use the following command to unstage the file:
git reset HEAD <filename>
git reset HEAD <filename>
Tuesday, April 2, 2013
Iterating Through All Loggers & Appenders in LogBack
Most people probably won't need it, but when you do, this will come in handy.
http://stackoverflow.com/questions/7064402/is-it-possible-to-find-logback-log-files-programmatically
http://stackoverflow.com/questions/7064402/is-it-possible-to-find-logback-log-files-programmatically
Monday, April 1, 2013
The "spi" Package in Java Projects
It's quite common to find a package called "spi" in Java projects.
Here's an explanation of what it means and what it's for:
Here's an explanation of what it means and what it's for:
Friday, March 22, 2013
C# Iterate Dictionary
Using "foreach" and "KeyValuePair" as the element. Refer to this: http://stackoverflow.com/questions/141088/what-is-the-best-way-to-iterate-over-a-dictionary-in-c
Monday, March 18, 2013
C# Start New Process
This is how it's done:http://stackoverflow.com/questions/258416/shellexecute-equivalent-in-net
If you need to start multiple processes asynchronously, you'd need to first start multiple threads and then within each thread, each process is started.
Reference for this: http://www.codeproject.com/Articles/25983/How-to-Execute-a-Command-in-C
How to add arguments: http://msdn.microsoft.com/en-sg/library/system.diagnostics.processstartinfo.arguments.aspx
If you need to start multiple processes asynchronously, you'd need to first start multiple threads and then within each thread, each process is started.
Reference for this: http://www.codeproject.com/Articles/25983/How-to-Execute-a-Command-in-C
How to add arguments: http://msdn.microsoft.com/en-sg/library/system.diagnostics.processstartinfo.arguments.aspx
Tuesday, March 12, 2013
C# Getting Time Since Epoch
Many things are simpler in C# than e.g. in Java, but getting the Epoch time is an exception, and this is how it's done.
| TimeSpan timeSpan = DateTime.UtcNow - new DateTime(1970, 1, 1); double currentTime = timeSpan.TotalSeconds; |
Tuesday, February 5, 2013
Ubuntu: Configuring Tomcat
Instead of hacking the startup scripts, some of the common configuration variables can be set in Ubuntu in the file "/etc/default/tomcat7"
Git Log Show File List
To list the files that were involved in each commit:
git log --name-status
References:
git log --name-status
References:
Subscribe to:
Posts (Atom)