Why are there no tutorials for Django using Windows? - windows

I'm starting to use Django and I find that every example I see is done in Mac OS. I'm a Windows user. I've used Mac OS X Lion and I have no problem with it other that my personal computer doesn't have it. I would prefer not to go out and spend money on an operating system and set up dual booting just to follow a quick tutorial for Django.
So my question Is, can anyone point me in to a tutorial that uses Windows so I can get a good idea of how it works, and get a good ground, so that I can translate the other tutorials a little more easily.
Any help would be appreciated.

There are no windows specific django tutorials because django as a framework is platform agnostic. All of the python code that goes into writing a project is the same across platforms. The only time you would see something different is when a tutorial references a path on the filesystem.
The actual installation process of django would however be platform specific, but thats more of just a python for windows question. It would be the same situation for installing any python package or framework.
Ultimately you only have a few commands you need to actually run when you are learning django:
python manage.py syncb
python manage.py runserver
python manage.py shell
How you call python is the platform specific part, but the django aspect is the same. The project file structure is also the same. As long as a project doesn't use platform specific file path references, you could run a project written under linux on windows.
This doc might be the only one you need, which explains various installation procedures:
https://docs.djangoproject.com/en/1.4/topics/install/
If you need more info, you might need to provide some specific examples of where its confusing you to see non-windows style tutorials.

Here's a slightly old tutorial: http://mirkobonadei.wordpress.com/2010/01/25/install-python-and-django-on-windows/
The official Django docs also have a section on installation, which covers Windows: https://docs.djangoproject.com/en/dev/topics/install/

Related

GUI Development for a ROBOT Compatible with ROS and WINDOWS

for a project i have been assigned, I have been given 2 robots...one has ROS and the other basically uses Windows. So my task is to develop one Graphic User Interface that can be used for both robots.
From the GUI , a user should be able to.
- Connect to the Robot
- Move and control the robot.
- Change speed...etc
I will like to ask for advice as i am about to start this project.
How can i go about this? and which has better support for my requirements?
From my research i have read people recommend QT...for cross platform developmens. Are there any other alternatives? any book recommendations?
The goal will be to have a GUI that is compatible for both systems. Any Recommendations or help is welcomed.
First you setup ROS On windows Using WSL (or any other ways to do it WSL is most stable).
after that you need achieve everything you want the GUI does on robot using ROS terminal.
after that your write the GUI. You can Choose any framework You want(You need C++ or Python for compatibility issues with ROS) but QT Framework is most used in multi platform Application and has a lot of support.
the compatibility with non-ROS is what You should Implement in your Application Like Choosing or something Like that.
PySimpleGUI is a framework built on top of tkinter that runs on the Pi. There are some example programs written to do robot remote control. There are GUI buttons designed specifically for "realtime" control of hardware that will provide immediate and constant feedback when a button is held.
It runs on Python 2.7 and 3 (recommend 3).
There is a Recipe in the Cookbook that matches your problem located here.
If you use PySimpleGUI in your project, post in the Issues area on GitHub if you have any questions and you'll get support.

Using Cygwin on enterprise-class applications

Is Cygwin considered robust and safe enough to be used on enterprise applications?
Do you know Enterprise applications that were developed or using Cygwin?
If you've been using cygwin - how often did you need support? Is there a fine-support for Cygwin? how well was the support you were given?
Thank you very much.
Why on earth would you even consider cygwin towards any sort of enterprise application? Even their site directly gives multiple signs it shouldn't be used for anything critical. You can't run native linux apps and you have to rebuild your app from source if you want it to run. It won't make your apps able to use any *nix functionality like signals, ptys, etc. All it is is a slim Linux type API layer....to answer your question, I don't think anyone would want to use cygwin in an enterprise application.
Like Maz asked, why wouldn't you just run linux? What potential benefits would you ever see coming from cygwin in an enterprise environment?
The best answer to your question may be obtained from the Cygwin web site. The answers obtained there come directly from the maintainers of the Cygwin DLL and ported software.

Mac OS and PackageMaker: Allowing user to choose language during installation

I am implementing a Mac application. Its Windows version is already implemented. Now I am facing the following issue:
implementation of the new package with multiple languages. I.e., for the Windows version of the software, when executing the installation file, the user can choose the language in which the application should be installed. I want this feature to be included in the Mac version.
Currently in the Mac version multiple language support is implemented using NSLocalizedString so that the app chooses a language according to the system language preference and the installation package is localized.
However, I specifically want the users to be able to choose the installation language of the app when installing. I am using PackageMaker now. Please help to solve this issue. I have been trying to implement this feature for several months, but no luck.
The official recommendation from Apple is that you shouldn't do that; just include all of the localization to the app just as you already do.
So, if it is not the requirement imposed on you by your employer, just don't do that and implement more useful things on your app.
The English user, who chose to install just English version, might suddenly marry a Japanese, who might want to use it in Japanese!

Developing in Ruby, on a Windows machine, is too counter productive?

It seems to be very counter productive in that so many gems will break on windows. I have been dealing with so many mysql and ruby-mysql gem problems (seg faults occuring in the gem itself, a class called UnixSocket apparently doesn't work well on windows machines, etc etc).
I'm I just wasting my time here? Should I move onto a different scripting language?
I have very little experience with Ruby on Windows but when I was starting with Ruby I was on Windows and I got the general impression that it wasn't a Windows-native system.
So after many years of using primarily Windows, getting into Ruby prompted me to switch back to my original system, Unix, this time to Linux. Ruby did run with less hassle and running bash in its native environment was better than the just-mostly-OK Cygwin. I was happy.
Then my new employer had me switch to the Mac. Now I'm really spoiled, but really happy.
I realize this is subjective but ISTM that Linux was a lot better than windows and the Mac is a lot better than Linux. I could still run Windows in VMWare Fusion if I wanted to, but I don't. I do have some Linux VM's.
I think what I'm really trying to say is that there is a reason Ruby isn't best deployed on Windows. The kind of people who run Ruby are .. I'm trying to think of a non-pejorative word here .. not likely to be found on Windows.
So this is a turning point for you. Yes, .net is a sophisticated and well-documented environment, yes, windows has been reliable for several years now, and yes, it's a respectable system at this point. Yes, it runs Stack Overflow and some of the gurus are Windows guys. But it's just kind of a litmus test for .. darn, missing that word again ..
A lot of people run Windows because they just don't know what else to run. Linux is a good alternative if you have to buy the system yourself. And if you or your employer can afford it, the (Unix-underneath) Mac gives you everything Linux does plus the Mac-specific world.
It's time to choose... :-)
I've been developing with Ruby on Windows for several years, including building and deploying "enterprise" intranet Rails apps running against Oracle, MySQL and SQLServer on both Windows and Solaris servers.
Agreed, there are a few gems that have compiled components whose authors have not built Windows versions - that's OK, it's an open-source platform and they don't have to if they don't want to. Similarly, you're perfectly entitled to (a) ignore libraries that don't have mswin32 or mingw32 versions or (b) give something back by compiling them yourself!
As for the MySQL gem, IIRC on Windows you need the "pure Ruby" adaptor, which does not use the MySQL C API: http://github.com/tmtm/ruby-mysql or gem install ruby-mysql
I don't think you're wasting your time. I've worked with two guys who've done extensive projects on Ruby on Rails apps using Windows XP, like major, long-term projects. They seem to not mind it at all. They both worked on it using the NetBeans IDE. (It has a Ruby-specific version.)
I tried it myself when I first got started with Ruby and didn't run into a lot of errors or problems with gems, though there were some things that worked awkwardly. Usually there was a workaround.
I decided that I greatly preferred using OS X or CentOS Linux for Ruby development. But I know for a fact that working on Windows is possible.
One thing to look out for is that 90% of the Ruby community is on OS X and deploys to Linux, so you'll get more help if you're on one of those OSs.
Another thing to look out for is that the whole Ruby universe and culture is very oriented towards the Unix command line using the bash shell. All your tutorials and stuff are going to kind of assume that. They're going to have instructions like "Go to the shell and run # rake db:migrate and it will be a lot easier to follow those instructions if you have a full-featured shell with command completion, command history, etc. So if you want to work on Windows you might look into installing something like MinGW.

Building a Windows executable from my Ruby app?

I'd like to be able to send a Ruby app to some colleagues without requiring them to install a Ruby interpreter. A single exe would be preferable.
I googled and found "RubyScript2Exe".
What are your experiences with that? Are there other such tools or are there better approaches altogether than building an exe?
I've used it about 3 times and I haven't had any problems with it and I ran one of the apps on 10 servers and never had any issues. So, I think RubyScript2Exe is about as good as it gets for ruby.
_why's Shoes framework lets you package the program as an executable for Mac or Windows that installs Shoes (contains a Ruby interpreter). Information about using the packager is here. _why also gives hints about how he makes the Windows executable here.
Don't forget OCRA [1] which I used a couple of times and which Just Worked.
I used to create my exes with RubyScript2Exe as mentioned above but had problems when used with Ruby 1.9 [2].
[1] http://ocra.rubyforge.org/
[2] http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/343891
There is another one called Crate. You can find some information about it here. However I haven't tested it on Windows.
Sorry to be late to the party, but I found this question in my search for trying to do this myself (starting to use SO more and more as a primary resource).
Anyway, I have just had success with exerb, although I'd add a couple of notes:
The web page says exerb runs on any platform. That is true; however if you "compile" a program calls out to native code, then exerb will embed your system's native code (e.g. Linux .so files) into the .exe. In practice, that means you have to build any significant app on Windows.
The web page also says ruby -r exerb/mkrbc but the actual command is ruby -r exerb/mkexy.

Resources