Lots o’ Love For oDrive

Dropbox was slowing my computer down an OUTRAGEOUS amount.  I had a large amount of data on it, and every time I booted or logged into my computer, it would scan the ENTIRE system for changes.

I have ideas for how they could stop this.  I hope they have these ideas, too, cuz there are lots of other things I love about Dropbox.

The other main problem for me with either Dropbox OR Google Drive, is that in order for me to be able to see my directory structure there, I have to let them store an entire duplicate copy on my hard drive of everything on my computer.  To me, this defeats the primary purpose of saving my storage space.

Screen Shot 2016-01-28 at 2.25.24 PM
Enter oDrive.  oDrive lets me connect to many different kinds of storage spaces and sites, including DropBox and Google Drive.  Instead of downloading everything from those places, it creates pointers to the information.

 

oDrive is fixing both of these issues for me; not hogging resources and bandwidth unnecessarily syncing data I don’t need to access, and not hogging hard drive space, while still letting me easily see what I have.

 

oDrive’s icon is also available just like any other drive in my Finder Window, and there’s a link to it on my Task Bar.

Screen Shot 2016-01-28 at 2.23.38 PM

When I click on it in Finder, I see all the connected areas showing as subdirectories.

Each time I drill down to a new level, it just-in-time syncs that level.  If that level has subdirectories in it, it shows me the pointers to those subdirectories.  If that level has files in it, it syncs those files.

You can visually tell which files and directories are synced/not synced, because the extension on the file/directory has .cloud or cloudf appended to the non-synced ones, and they also have pink added to the standard icon.

Screen Shot 2016-01-28 at 2.24.38 PM

It’s also easy to right click on whatever I’ve previously synced, and un-sync it I’m done using it.

Screen Shot 2016-01-28 at 2.29.36 PM

 

The only real limitation I’ve run into so far is in the File Save dialog box on my Mac.  I wanted to save something in a subdirectory I didn’t currently have synced.  I can see the pointer to it, but if I try to sync it from there to have it available, no-can-do.

I’m guessing oDrive doesn’t have programmatic access to do that in Apple’s File Save dialog box, the way they clearly do to the Finder window. I’m assuming that File Save dialog box has whatever features Apple’s given it, and has limited any third party’s ability to change its functionality to support something like this.

I was able to solve this issue easily by going to Finder, and syncing that directory.  As soon as I did that, it was available in my already open File Save window, because Apple dynamically updated it.

Ironically, I discovered this limitation when I was trying to save a spec sheet on a NAS Drive I have.  I’m in the middle of going through all my old data, trying to get it all archived and/or organized in a single location.  I’m unable to access the NAS drive right now, and was researching it, when I found the spec sheet.

Stay tuned to see if I manage to access the data on the NAS drive.  It’s DEFINITELY proving worlds harder than accessing my data through oDrive.

Turn a list into a quoted, comma-delimited line of text with VI

Here’s how to turn a column of information into a quoted, comma delimited line of text, using VI

Original text:

fred.smith
j.johnson
why.not
When.ever

Desired result:

“fred.smith”,”j.johnson”,”why.not”,”When.ever”

PHP Usage:

$data_array = array(“fred.smith”,”j.johnson”,”why.not”,”When.ever”);

How To:

Open the original text list in a VI editor (My favorite is Mac-VIM)


PART 1 – QUOTE AT THE BEGINNING OF EACH LINE

ESC to make sure you’re in command mode
:1 goes to the first line
CTRL-v visual block mode)
Shift+g capital G – goes to the beginning of the last line in the list)
Shift+i capital I – insert mode at the beginning of a line)
the quote character desired at the beginning of each line)
ESC wait a second, and a quote will appear at the beginning of every line)

PART 1 RESULT:
“fred.smith
“j.johnson
“why.not
“When.ever

PART 2 – END OF THE LINE CHARACTERS

Now for the end of the line –
Desired appendage: “,
Assuming VI is still in command mode; If it isn’t, ESC
Type In:
:%s/$/\”\,/g
DISSECTED:

: lets VI know you’re entering a command
%s search from the beginning to the end
/ indicates the end of the command instructions for where to search
$ put something at the end of every line
/ indicates the end of the portion of the command for telling VI where to put the character; in this case, the end of the line
\” The quote character for the end, escaped with a backslash because it’s a special character
\, The comma for the end, escaped with a backslash because it’s a special character
/ indicates the end of the portion of the command instructions for what to insert
g tells VI to do this globally

PART 2 RESULT:
“fred.smith”,
“j.johnson”,
“why.not”,
“When.ever”,

PART 3 – REMOVING END OF LINE CHARACTER WITHOUT SPACES BETWEEN

Type In:
ggVGgJ

DISSECTED:

ggVG globally select everything in the whole file gJ remove all the end of line characters, and don’t put a space in their place.

PART 4 – REMOVING THAT LAST TRAILING COMMA

Shift+g (goes to the end of the document)
x (removes a character, in this case the very last comma)

PART 4 RESULT:
“fred.smith”,”j.johnson”,”why.not”,”When.ever”

ALL DONE.  I love VI.
Voila!

Code Igniter – Authentication

Here are libraries and discussions about CodeIgniter Authentication:

http://stackoverflow.com/questions/4977707/codeigniter-authentication-user-privileges

https://github.com/benedmunds/CodeIgniter-Ion-Auth

https://github.com/haseydesign/flexi-auth

http://haseydesign.com/flexi-auth/auth/register_account

https://github.com/kabircse/CodeIgniter-Aauth

http://community-auth.com/

http://blog.pisyek.com/5-best-authentication-libraries-for-codeigniter/

https://bitbucket.org/skunkbad/community-auth-for-codeigniter-3

http://stackoverflow.com/questions/33311725/codeigniter-3-x-authentication-library

https://github.com/benedmunds/CodeIgniter-Ion-Auth

http://stackoverflow.com/questions/549/the-definitive-guide-to-form-based-website-authentication?rq=1

Here’s what I’ve set up in PHP in the past

  • Roles – what application tasks they can do
  • Groups – what data they can access or do tasks on
  • Services – what tasks the application can do
    • Services might be a bit different with Code Igniter – CRUD in models, controllers and views