I'm starting a new web project, and I'm looking to learn more about Xcode at the same time, so I'm wondering if there's a good way to manage the project through Xcode?
In an ideal world, I would like the "Run" button to upload the final product files to the web server (or copy them to some local folder that is set to auto-sync using an FTP client) Then I would like it to launch safari (and a number of other test browsers) and have them open the home page.
Additional features that I think are possible:
Have local environment variables that are substituted by some kind of text find/replace action into HTML files as they are copied.
My advice is to stay away from XCode for Web development. While it can be done, it really isn't built for it and you will only make things much more difficult than it needs to be. If you really want to learn about XCode then use it for application development, not web development.
There are other IDEs out there specifically for web development that you might like. NetBeans, Coda, Expresso, etc. Personally, I enjoy using Expresso.
Related
A friend has asked me to do some work on his existing site which was built in Rapidweaver. I'm on Windows, so is there another way I can access and edit his site?
The Rapidweaver project file is meant to be edited only in Rapidweaver, really. As far as I know, the only way around would be to use an HTML editor to modify the pages that are already in the server. However, I would not reccomend you to do it unless you are not going back to Rapidweaver anymore. Because changing the files in the server does not update your local Rapidweaver files. So, you could end up editing something in the server, then getting back to Rapidweaver and upload a "new" version that would not be completely up to date (the previous changes in the server version would be overriden by the older rapidweaver project).
For that kind of work, a CMS (Content Management System) is a more flexible way to work. Nowadays, one of the most common is Wordpress. It will require an inicial setup but after it is working it can be updated from anywhere via web browser, or even from an app in your iPhone. But it is not a Rapidweaver based sollution.
There are a couple CMS related plugins or stacks (Dropkick CMS, Armadillo, Easy CMS, Total CMS...) for Rapidweaver that could also be useful in this context. Once again, first you would need to buy a licence and to setup the website using one of those plugins or stacks. Only then you would be able to edit on the go.
I am developing a SPA application on ASP.NET 5 and I wanted to go one step further and separate the client (js, html, etc.) and the web api projects so that there is clear distinction between client and the server. Apparently there are number of technical issues that complicate things:
How can I include the js/html/etc. files in the resulting published project? (Ideally I want to be able to edit js/html and see the result in the browser on the fly). There is on way that I found to have a linked folder.
I want to share some of the javascript files even further e.g. angular services in Cordova js projects
There is very nice feature in mvc6 with environments that is not easily done in js project and I would have to still use some Index.cshtml to use it, but this is not critical though since I can use gulp to do similar stuff
How will the js know the URL of the api (this can probably be just done using gulp as well in some script with configuration)
I am not 100% sure this is a good idea at all, but maybe someone has tried it and can share experience and pros/cons of this approach. For now the most important problem seem to be of including the client project into the service project somehow so that they are joined into one web application that I can deploy in a way that does not make development harder.
I am using Visual Studio 2010 and IIS 7.0 .Currently when I want to deploy an website to my web server I follow these steps -
1.Right-click on website and say publish..to get the entire site copied to a local folder.
2.Next using filezilla just ftp the copied files to the web server.
The problem is I have to deploy entire website all the time since I can't keep a track of the changes. Although I do find my way easier and without problems. I dont want to a whole lot of configuration and deployment packages unless it is really worth it and also relatively easy to do. Is there a better way I should do the deployment ? Any suggestions are welcome !
You could use the Web Deployment tool. It needs to be installed on the webserver too and can even take care of publishing a sql server database.
http://www.iis.net/download/WebDeploy
Do NOT use the Web Platform installer to install this package.
You can just right click on website and Publish Web Site; the Publish Website Wizard opens. You can click the ... button to browse on the Target Location textbox and choose FTP over in the left hand side, then put in your FTP credentials.
You can tick 'Allow this precompiled site to be updateable' so if you need to make minor changes (such as scripts, css, or html) but I don't know how reliable that is.
Good luck!
Scott Gu just published an article about the Deploy Features in VS today:
http://weblogs.asp.net/scottgu/archive/2010/07/29/vs-2010-web-deployment.aspx
Personally I use Dispatch for ASP.NET. Works well for me. It only uploads the files that have changed and can check for files that are missing locally or on the server.
http://dispatchasp.net/
If you are using the Publish Wizard then you have no choice but to deploy the whole site. There is no way for the wizard to look at the files on the server and know definitively if the file has changed or not (it could look at file size or something, but that's not 100% guarantee of no change and FTP doesn't offer an easy way to do a checksum algorithm).
Other then that, do it the way you would do it on any other language/tool. Just manually FTP the files you've changed. Of course, this means you have know which files are side-affected by your changes. And if you're not confident as to what files you've side affected.... publish wizard is your friend :)
we've recently stumbled across the excellent Dispatch for ASP FTP deployment plug in. It looks great apart from one thing: It doesn't work with Visual Studio 2010, at least for us, anyway. (It's supposed to work fine.)
(Yes, we've tried everything: We've managed to get Dispatch working for another FTP site, but not the main one we regularly deploy to. We have managed to connect to our main site through FileZilla FTP, so the site itself is configured correctly. All settings have been triple checked, but the software still throws up weird errors (always to do with its internal libraries).)
So does anyone know of any other comparable FTP-based, deployment plug-in for Visual Studio?
Here's what Dispatch does (and so any suggested replacement must do):
Monitor any altered files
in the project. When a file is
changed, it's added to a list of
files to be deployed.
To deploy these
files to the live site, all we need
to do is click "Upload" and the plugin will
connect via FTP to our live site and
upload the selected files.
We can filter out
any filenames we don't want to be
monitored/uploaded (e.g. .cs or
web.config or /Images/, etc.)
I think that's all the features that we need. Thanks for any suggestions!
Note: If you're wondering why we need such a service, it's because we deploy many site changes over the course of a single day. Publishing the entire project to a folder, zipping it up, then FTPing that zip file, only to have to unzip it, and then install the entire project into the live wwwroot takes far too long. With Dispatch you're able to upload individual files in a single click.
After much back and forth between me and the creator of Dispatch, we managed to narrow down the problem to the library he was using (Rebex FTP). I posted a question about the issue on the Rebex forums, and it was revealed that their software might have a bug with IIS7.5. They suggested a quick hack/fix, which I tested and discovered worked.
Mr. Dispatch then quickly implemented this hack/fix into his software, and lo! I had a fully working copy of Dispatch... So no need for a replacement any more!
(And from what I've seen, there isn't even any other plug-ins offering this functionality, so it's just as well.)
Just an update - Dispatch does not work with VS 2013 so if you have VS 2012 with Dispatch installed, Keep it. Also the website is gone so it looks like all development has ceased. I have been using Dispatch since VS2005 and it has been great for just sending single files up when I need to. Too bad it is gone.
I built a very simple one for myself - you right click the file in Solution Explorer and it then uploads that file based on a settings file you create.
It's super crude but it works and the source is there to make it better if you like -
https://github.com/garazy/vs-2017-ftp-upload
Big enhancements have been added to VS2008, VS2010, VS2012. Below is the article. I found that Microsoft did all the above while I was searching. Since this came up high in what I was searching, thought should share this knowledge.
Deploy a Web Application Project Using One-Click Publish Without Web Deploy
I am thoroughly in love with TextMate. I program everything in it, including ASP.NET for my daily job. However, I have a license for Espresso, and I was looking at it recently and discovered that there is a "Publish" section that I knew about before, but I didn't know that it could compare my FTP directory with my local directory and publish only the changed files.
Over the past week I've been finding myself using Espresso just for that functionality. However, I was hoping there was a way to get this functionality inside TextMate. I know that you could use an AppleScript script with Cyberduck (my FTP client) to upload a file when it changes, but I have never got that working and it also doesn't include the ability to merge files like Espresso does.
Am I plumb out of luck? Am I stuck using two different programs for the forseeable future?
I haven't tried it, but you should be able to set up a simple rsync command in a bundle in TextMate that will use environment variables from your project to synchronise.
See Using rsync to enable the project drawer in TextMate while working on a remote server for an example.