Pages

Monday, April 6, 2020

365 Day Graphics Design Challenge


In a discussion with my eldest, he brought up the fact that with all of my skills with computers that I had no skills with graphics. Now I had to argue the point. I am a technical person and have done some graphics work but of course it is of a technical nature. So I will admit to being a rank amateur.

I have always meant to gain some skill in the graphics design arena. I have never taken the time to study it. If I have something I need of a graphical nature I can find it. Or create it. After a fashion.

I have been able to put together some nice (my opinion) bits. Most would have to be considered a montage of sorts. But that is fine. I probably only needed it to add a bit of flair or color to another project. I have never really created a graphic that was meant to stand on its own..

A lot of what I have done with graphics was something to add to a blog, or newsletter, article. And some of it was for illustrative purposes for presentations. Working with PowerPoint there are some very interesting effects one can achieve, especially with animations.

The 365 Day Challenge


So, back to the gist of this article. I am challenging myself to create a new graphic for any purpose. To do a new graphic every day. Except I know that life tends to get in the way, so five days out of seven is acceptable.

And I expect to start with “baby steps” and increase in complexity as I go along. That, or learn a new technique on a given day. So some “projects” may require more time than I have available on a given day. These projects then will consist of multiple days. I will include “works in progress” as the graphic on some days.

I also am expecting to limit myself to non-commercial tools. Looking for quality, or usable, online tools or open source ones. Some projects will be “off-the-cuff” pieces that may also be used in a project or article. Other pieces may be the results of tutorials. Have to learn from somewhere, eh?

Day 1 Graphic


The graphic for day 1 is the one at the top of this page. It was created with an online photo designer, Fotor. This appears to be a great, little program. It is free to use with a premium paid version.

I am not writing a review of Fotor here. Or creating a tutorial on its use. But I am planning on learning more about this app and looking forward to putting it through its paces.
In this instance I did a simple text on the face of the photo. The photo itself is a picture of the corner of a painting that my wife received as a gift. This is a simple graphic with the picture as background and simple white text overlaid on it.

Nothing very fancy but it serves its purpose for this article. A simple, easy graphic that serves a purpose. And the use of a freely available online app.

Editing GitHub Pages on Windows

GitHub Pages can be maintained and edited in place on the GitHub site. But why not clone the repository with your Page to your working computer. That way you are able to make and test your changes. And push them back up to the site when you are satisfied with them.

This article will cover doing just that on a Windows laptop which is what I am using. Those of you on Linux or Apple boxes can still follow around and work from a terminal on your system. There will be a few more steps for Windows users.

 I love Linux, have never spent much time with Apple devices, but would like to set up a development system for GitHub Page. GitHub Pages utilize Markdown to write page content which  is much easier to read than formatted out HTML. And when publishing you can output the Markdown to HTML, using something like Jekyll, to be posted on your site.

Jekyll is what GitHub uses to convert your Markdown to HTML. Good time to learn Jekyll then is it not? So let us get started.

Getting Started with Jekyll


For your own system you will need Ruby, the programming language. Then an installation of Jekyll. For Windows users this is an issue. It is possible to run Jekyll with a Windows Ruby installation, but it is not officially supported.

The answer is to add a Linux installation to Windows. And the simplest way to go about this is to use the Windows Subsystem for Linux. This will allow you to load a Linux distribution of your choice for development purposes. The WSL does not support a GUI so you will be limited to a CLI. But that is all that is needed for this Linux installation.

There are a number of distributions to choose from. So pick your favorite and enjoy. If you are not sure about which distribution to go with, Ubuntu is a common distribution.

There may be more than one Ubuntu distribution to choose from. I chose the 18.x.x version. It was the latter of the two to choose from. The earlier version may be better if you have a slightly older machine.

You can follow the detailed installation guide, Windows Subsystem for Linux Installation Guide for Windows 10. Once installed you will need to initialize your distro and go through the new user setup. Also,you need to perform an update/upgrade of your Linux Distribution.

Install and Setup Jekyll

Open a terminal screen and login. For Windows, I am assuming you are starting up your WSL Linux distro. Jekyll is a Ruby Gem. So you will need Ruby and RubyGem along with standard Linux development utilities. Check for them and their version with (ruby -v), (gem -v), (gcc -v), (g++ -v), and (make -v).

If you don’t have them, you will need to install them. See the Jekyll Installation page for instructions for your OS. We will cover the Windows installation through your WSL Linux shell.

If you have the Ubuntu distro installed, follow the Ubuntu installation guide. Else, choose the guide for your OS. Install Ruby and the required dependencies. Add the Gem installation and environment variables to your  bashrc file, per the instructions. Then install Jekyll. Pat yourself on the back, it is finished.

It is not required but you might want to install the gem Bundler. The instructions are available on the Ruby 101 page. Don’t worry though, the Bundler installation is included in the tutorial. Here is where I suggest you follow the tutorial, and where the fun begins: the Jekyll Step-By-Step tutorial.

So enjoy and study up on the capabilities of Jekyll, YAML Front Matter, Liquid templates, adding Data, asset and static files, and so much more. Have fun, I know I will.

Addition:

Setup your directory structure (folders) as you see fit. Please feel free to use your favorite Linux editor. Nano is quick and easy. And if you are not familiar with the Linux command line interface (CLI) take the time to work through a Linux CLI tutorial. You can find one easy enough.

On Windows, you can edit files in your WSL Linux system with VS Code. My article on Coding on Windows with Linux will help you set up for using Code to edit files on your Linux system. This is a good way to manage your projects and track your changes with Git.

It is possible to access files on your Linux file system from Windows but only if you have Windows 10 Build 18836 or newer. I’m not so lucky. Besides, you need to start Explorer from inside your Linux system. Probably wouldn’t work for what I wanted if I had the newer Windows build.

I would like to be able to access the /site builds from a Jekyll run. It is easy enough to do that by copying the /site folder from a Jekyll project to a Windows mounted hard drive. Yes, the Windows file system can be accessed from your WSL Linux system through the /mnt/c (for hard drive C).

So why not create a folder on the C drive for your Linux files system to use as a work space and then you can access it from your Windows file system with ease. That is what I did. Created a Home folder with “mkdir /mnt/c/Home” from my Linux system command line.

And this is where I run into a problem. From inside my Linux distro’s shell I can run Jekyll new, build, and serve commands on the Linux file system just fine. But errors are generated running the same commands on the Windows file system.

These errors appear to be permission errors but I am unable to pin them down and find a fix. I will keep working on this. May have to wait for an update to the Windows Subsystem for Linux from Microsoft. All of this is from the command line.

My hope was to be able to run Jekyll under Linux with WSL and access the input files for Jekyll and placing the output files on the Windows file system. This is currently undoable at this time, at least from the Linux command line. But the idea was to develop web sites with Jekyll in Windows.

Jekyll projects can be set up and initiated from the Windows side utilizing VS Code. Make sure you have WSL up and running. Check the lower left corner of your Code screen for the WSL indicator. Then open the terminal into your Linux system.

Have Fun. There is more. Look for the blog on using VS Code to run Jekyll and post to GitHub. And maybe throw in a bit on GitHub Desktop.

Friday, April 3, 2020

Your Own Website on GitHub

Are you using GitHub but Not using GitHub Pages? Maybe you should be. GitHub Pages are for you or your organization to have a front facing website. And also for providing a Page (website) for each of your GitHub projects.

GitHub Pages logo

This article is more of a guide to putting up a personal, or organizational, Page of your own. This is not a comprehensive tutorial. Only a simple guide with links to the same information I used to set up my Pages.

For an introduction into precisely what GitHub pages are all about, check out this article on GitHub Help: “About GitHub Pages”.

Setting Up Your Page


First off, let’s get a Page up for your GitHub account. LogIn to your GitHub account and create a new repository named username.github.io. Use your actual account name followed by .github.io.

Then, select the Settings tab, go down the page to the “Theme Chooser” and select the Choose a Theme button. Select a theme from the Theme Chooser to finish setting up your page. Change the default index page by editing the index.md file.

After changing the content of the index.md file, commit your changes. Your page is complete. To view your page go to your-username.github.io.

Your theme may be changed any time. Just remember to keep your page info up to date. For detailed instructions of this procedure, go to https://guides.github.com/features/pages/.

Editing Your Page


We have already looked at editing your index.md file. GitHub uses Markdown quite a bit on it’s site. Check out the Mastering Markdown page for a good introduction.

Editing Your Page Offline


For some additional power in editing your Pages, check out Jekyll. Jekyll is a static site generator. It has some true power and can be used for converting Markdown to HTML and integrating your Pages with templates. It is a great package for creating and editing a static file website.

And GitHub uses Jekyll for it’s Pages. So learning Jekyll can be another tool for your toolbox. Here is additional information About GitHub Pages and Jekyll.

Tuesday, March 31, 2020

Coding on Windows with Linux

Windows Subsystem for Linux is cool as cool can be. That is putting it mildly. I know not everyone will agree but bear with me. Hopefully my enthusiasm for this system is catching.

Code showing path
Code showing Linux path
I have separate laptops for Windows and Linux development. I spend more time in Windows than I care to admit. I haven’t needed to really merge the two before. But the need evolved in a subtle way.

GitHub has an interesting repository that I forked to use for myself. Chuck Groom’s One Page Bio “is an example one-pager site that prospective job-seekers can use to quickly highlight their accomplishments and make an introduction”. Very interesting example of an online bio. And I decided to use it.

Digging into the codebase I came across a few things I was not familiar with and some I had heard of but have no experience with. The long and short of it is I needed to familiarize myself with Jekyll and the fact that it is a Ruby Gem. Not part of my toolset so looking into installation there was an indication that there could be issues running on windows at times.

So why not use Linux? A quick look for Linux on Windows pulls up some options. And here is where the Windows Subsystem for Linux co mes into play. Another one of those things I had seen before but not tried. Used to have Linux installed in it’s own partition and I have used live CD/DVD versions before.

But the WSL looked like just the right thing. Easy install. And it is just as easy to remove. So why not?

Installed WSL. Started using it. Installing software just like any other Linux package. I even has a choice of Linux distributions so went with the old tried and true Ubuntu. It all worked like a charm.

Went ahead and installed Ruby and Jekyll. Then went through the whole 12-step Jekyll tutorial. Great little tutorial. Walks one through setting up a blog all the way to deployment. Easy to use, easy to learn, easy to understand. Can’t wait to try on a project of my own.

Which is interesting. I ended up using some of what I just learned going through the GitHub Learning Lab course on GitHub Pages Training. GitHub Pages uses Jekyll. Who would’ve thunk it?

So, back to the focus of this article. VS Code for an editor on Linux. I had heard it was available and I needed something more comprehensive than Nano. Upon looking for a version of Code for Ubuntu Linux I found references to using VS Code with the Windows Subsystem for Linux. Not quite what I wanted. Or was it?

The Windows Subsystem for Linux is a command line only system. No GUI available. Good enough for coding but not for a GUI based code editor. Which leaves out VS Code. At least for running directly on the Linux system.

But the WSL integrates well with the hosting Windows system. Drives are mounted such as the C hard drive which is available at /mnt/c. Easy enough to copy files to or from while using the Linux system.

Here comes the great part. With VS Code on your windows system, it will detect the WSL installation. So start up your VS Code app. And it should give you the option to install the Remote - WSL extension. If you don’t see this option, you may have to look for it.

Remote WSL extension

There is also an option for connecting with extensions for Python, SSH, and Containers. Would you like to see a step-by-step on installing the WSL and connecting to VS Code? Let me know with a comment.

Finally, I found this to be a very usable system. VS Code can be started from inside of your Linux system. And you are able to access the Windows file system and your Linux file system from within VS Code. Will be giving it a workout.

Links:




Friday, December 13, 2019

Easy Python Web App Creation with Web2Py


There are a lot of ways to create a web based application in Python. I have tried quite a few out and my number one pick is Web2Py. It has all of the bells and whistles already built in. You can start out with a simple scaffolding app that is ready to run and modify it to learn how the system works.

You don't have to be a programmer or web developer to use Web2Py. You will just be ahead of the game a bit if you know some Python and/or some web technologies. Web2Py is a "free open source full-stack framework for rapid development of fast, scalable, secure and portable database-driven web-based applications".

The Web2Py web page is easy to navigate and very comprehensive. Everything you need to learn to use this framework is available from their front page. There are plenty of examples, tutorials, and a very comprehensive manual available.

Everything you need to build a simple web app up to an enterprise level system is built in. As they state, everything you need and "batteries included". Web2Py even includes a web based IDE along with an SQL database system. And one Web2Py instance can run multiple web apps.

Getting started is fairly easy. There are binary packages available for Mac and Windows systems that are ready to run. They even included a web server and Python 2.7.

For those with a little more familiarity with web systems just download the source code and install to your web server. You will need Python installed. You can choose Python 2.7 or 3.5+. It really is an easy to setup and run framework.

If you would like to have it available online and not installed on your own system, check out PythonAnywhere. It is a very easy to use system to host and run your own python code in the cloud. For a quick tryout of Web2Py and PythonAnywhere, try out their PythonAnywhere/Web2Py sampler wizard.

Web2Py really is a quick and easy way to get started with web app development using Python. I'm thinking of doing an article on setting up Python and Web2Py on a XAMPP development system. If you are interested, please leave a note.

I could also do articles on Progressive Web Apps with Web2Py and setting up your Python development environment on PythonAnywhere. Please let me know if you are interested by leaving a note.

Note: PythonAnywhere is a great system for teachers who are teaching Python programming.

Tuesday, April 23, 2013

Dan's Computer Tip #3: Spybot Search and Destroy


3D Spybot2.0 StartCenter2 300x271 Spybot 2 now available.

Spybot Search and Destroy is one of my favorite programs of all time. Like many of you, I spend an inordinate amount of time on the internet. Mostly researching, but I do plenty of surfing and socializing too. The biggest problem is all of the spyware that is out there. All trying to track your every move and report back to the mother ship.
This isn't all necessarily bad. Relevant ads are better than stuff you will never need. Or ever want to see. But the tracking cookies and other spyware the various sites you visit place on your system don't always play nice.

Spyware being installed on your system can cause your system to slow way down. I myself don't understand how I can garnish dozens of tracking cookies and hundreds of temporary files from a simple session where I only visited a handful of sites. I am wondering if a substantial number of  these are coming from my Google searches.

I might should start surfing anonymously and maybe look into some of the alternative search engines. I have just become accustomed to using Google for most of my research. Luckily I have Spybot S&D to help me keep all of this chaos in check.

A good antivirus program should keep your system relatively free of infections, no one program can protect you against everything. Spybot S&D helps keep certain malware at bay. Even if your antivirus system is performing more than adequately most antivirus systems ignore tracking cookies and certain other spyware. That is why I use and recommend Spybot S&D to everyone.

Spybot Search & Destroy is part of my triumvirate of must have programs on every Windows computer. The other two of course are the subjects of my first two tips. See my posts on Cleaning Your System and Microsoft Security Essentials for antivirus. I can't see operating a windows system without these three and put all three on the top of my list of recommendations.

 For instructions on how to install and use Spybot Search & Destroy, check out these links:



For additional information on Spybot Search & Destroy, check out these links:




How to Setup a Portable C++ Development System

Here is a quick and easy setup for a Portable C++ development system. Great for school or just to play around with. Enjoy!


Portable C++ Development System slide show.

This presentation was put together to help out a professor friend at a local state college. The development system works great from a USB drive. Hope her students all enjoy.

Portable C++ Development System