Skip to content

Commit 9810637

Browse files
committed
Version 0.6.2
- Implement ± Default Hosts - Allow alternative installation directory (still working on it) - Improve Help Instructions - Added edit status to tabs (need to implement undo) - First steps in theming (not ready yet)
1 parent 1f890ca commit 9810637

9 files changed

+289
-151
lines changed

compile.bat

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# electron-packager . --overwrite --platform=win32 --arch=x64 --prune=true --extra-resource="resources/fakemail" --out="..\release-builds"
1+
rem electron-packager . --overwrite --platform=win32 --arch=x64 --prune=true --extra-resource="resources/fakemail" --out="..\release-builds"
22

33
npm run dist
4-
# cd "../electron-builder/edit-virtual-hosts/";
5-
# mv "mac" "Edit Virtual Hosts macOS";
4+
rem cd "../electron-builder/edit-virtual-hosts/";
5+
rem mv "mac" "Edit Virtual Hosts macOS";

data/mamp-default.vhost

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# MAMP !! Do Not Repeat !!
2+
NameVirtualHost *:80

data/mamp.vhost

-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# MAMP !! Do Not Repeat !!
2-
NameVirtualHost *:80
3-
41
# MAMP [project]: [domain]
52

63
<VirtualHost *:80>

data/xampp-default.vhost

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# XAMPP Required Default !! Do Not Repeat !!
2+
<VirtualHost *:80>
3+
ServerName localhost
4+
DocumentRoot "[htdocs]"
5+
<Directory "[htdocs]">
6+
Options Indexes FollowSymLinks Includes execCGI
7+
AllowOverride All
8+
Require all granted
9+
</Directory>
10+
</VirtualHost>

data/xampp.vhost

-11
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,3 @@
1-
# XAMPP Required Default !! Do Not Repeat !!
2-
<VirtualHost *:80>
3-
ServerName localhost
4-
DocumentRoot "[htdocs]"
5-
<Directory "[htdocs]">
6-
Options Indexes FollowSymLinks Includes execCGI
7-
AllowOverride All
8-
Require all granted
9-
</Directory>
10-
</VirtualHost>
11-
121
# XAMPP [project]: [domain]
132
<VirtualHost *:80>
143
ServerName [domain]

index.html

+47-29
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,14 @@
2929
<button value="misc-text">File</button>
3030
<button value="misc-actions">Actions</button>
3131
</div>
32+
<div id="choose-server-root">
33+
<label for="server-root">Server Root</label>
34+
<input type="text" id="server-root" name="server-root" value="" placeholder="Leave empty for default" title="Full Path to Server Folder">
35+
<button name="server-path">Select Folder …</button>
36+
</div>
3237
<div id="misc">
3338
<select name="server" size="1">
34-
<option value="">Server</option>
39+
<option value="">Choose One</option>
3540
<option value="xampp">XAMPP</option>
3641
<option value="mamp">MAMP</option>
3742
<!--option value="ampps">AMPPS</option-->
@@ -42,9 +47,11 @@
4247
<form id="hosts-file">
4348
<div class="help">
4449
<h3>Hosts File (etc/host)</h3>
45-
<p>Add:</p>
46-
<pre>127.0.0.1 www.example.com</pre>
47-
<p>or something like it to the bottom of the file</p>
50+
<ol>
51+
<li>Add:
52+
<pre>127.0.0.1 www.example.com</pre>
53+
or something like it to the bottom of the file</li>
54+
</ol>
4855
</div>
4956
<div class="textarea etc">
5057
<textarea name="content">Open hosts file or Select Platform</textarea>
@@ -53,17 +60,19 @@ <h3>Hosts File (etc/host)</h3>
5360
<form id="httpd-conf">
5461
<div class="help">
5562
<h3>Apache Configuration File (httpd.conf)</h3>
56-
<p>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</p>
57-
58-
<p>Find <a href="doit:find:httpd-vhosts.conf"><code>httpd-vhosts.conf</code></a> and remove the comment(<code>#</code>) at the beginning of the <code>Include</code> (if any).
59-
This gives:</p>
60-
<pre># Virtual hosts
61-
Include etc/extra/httpd-vhosts.conf</pre>
62-
<div class="macos">
63-
<p>(MacOS:) Find <a href="doit:find:User/Group"><code>User/Group</code></a> and change the User and Group to your own. Something like:</p>
64-
<pre>User fred
65-
Group admin</pre>
66-
</div>
63+
<ol>
64+
<li>If you have installed in a non-standard location, enter it in the <strong>Server Root</strong></li>
65+
<li>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</li>
66+
<li>Find <a href="doit:find:httpd-vhosts.conf"><code>httpd-vhosts.conf</code></a> and remove the comment(<code>#</code>) at the beginning of the <code>Include</code> (if any). This gives:
67+
<pre># Virtual hosts</pre>
68+
<pre>Include etc/extra/httpd-vhosts.conf</pre>
69+
</li>
70+
<li class="macos">
71+
(MacOS:) Find <a href="doit:find:User/Group"><code>User/Group</code></a> and change the User and Group to your own. Something like:
72+
<pre>User fred</pre>
73+
<pre>Group admin</pre>
74+
</li>
75+
</ol>
6776
</div>
6877
<div class="textarea etc">
6978
<textarea name="content">Open httpd.conf file or Select Platform</textarea>
@@ -72,9 +81,12 @@ <h3>Apache Configuration File (httpd.conf)</h3>
7281
<form id="virtual-hosts">
7382
<div class="help">
7483
<h3>Virtual Hosts File (httpd-vhosts.conf)</h3>
75-
<p>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</p>
76-
<p>First, use the <strong>Generator</strong> tab and fill in the details.</p>
77-
<p>Then copy the result and paste it below.</p>
84+
<ol>
85+
<li>If you have installed in a non-standard location, enter it in the <strong>Server Root</strong></li>
86+
<li>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</li>
87+
<li>First, use the <strong>Generator</strong> tab and fill in the details.</li>
88+
<li>Then copy the result and paste it below.</li>
89+
</ol>
7890
</div>
7991
<div class="textarea etc">
8092
<textarea name="content">Open vhosts.conf file or Select Platform</textarea>
@@ -83,10 +95,13 @@ <h3>Virtual Hosts File (httpd-vhosts.conf)</h3>
8395
<form id="generator">
8496
<div class="help">
8597
<h3>Hosts Generator</h3>
86-
<p>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</p>
98+
<ol>
99+
<li>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</li>
100+
<li>Fill in the details blow and click <strong>Generate</strong></li>
101+
</ol>
87102
</div>
88103
<div class="etc">
89-
<p><label class="server xampp"><input type="checkbox" name="xampp-default" value="1" title="Short Project Name" checked> Include Default Host</label></p>
104+
<p><label class="server xampp"><input type="checkbox" name="vhost-default" value="1" title="Short Project Name" checked> Include Default Host</label></p>
90105
<p><label for="project">Project Name</label><input type="text" id="project" name="project" value="example" placeholder="Short Project Name" title="Short Project Name"></p>
91106
<p><label for="domain">Virtual Domain</label><input type="text" id="domain" name="domain" value="www.example.com" placeholder="Site Domain Name" title="Virtual Domain Name"></p>
92107
<p><label for="root">Document Root</label><input type="text" id="root" name="root" value="…/…/example" placeholder="…/…/example" title="Full Path to Root Folder"><button name="path">Select Folder …</button></p>
@@ -97,15 +112,18 @@ <h3>Hosts Generator</h3>
97112
<form id="php-ini">
98113
<div class="help">
99114
<h3>PHP Configuration File (php.ini)</h3>
100-
<p>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</p>
101-
<p>Find <a href="doit:find:sendmail_path"><code>sendmail_path</code></a> and remove the comment(<code>;</code>) at the beginning of the line(if any).<br>
102-
Select the part after <code>sendmail_path=</code><br>
103-
Locate your (fake) <a href="doit:open:Sendmail Path:clipboard">sendmail</a> program and add the path at the end inside "quotes".<br>
104-
This gives something like: <code>sendmail_path = "…/…/sendmail"</code>. Paste the resulting path.</p>
105-
<p>While you’re at it, check <a href="doit:find:extension ?= ?.*gd"><code>extension=gd</code></a> and remove the comment(<code>;</code>) at the beginning of the line(if any).<br>
106-
This will enable you to use image functions in PHP.
107-
</p>
108-
115+
<ol>
116+
<li>If you have installed in a non-standard location, enter it in the <strong>Server Root</strong></li>
117+
<li>Make sure that you have selected the server (XAMPP or MAMP) from the menu.</li>
118+
<li>Set the <strong>sendmail path</strong>:
119+
<ul>
120+
<li>Find <a href="doit:find:sendmail_path"><code>sendmail_path</code></a> and remove the comment(<code>;</code>) at the beginning of the line(if any).</li>
121+
<li>Select the part after <code>sendmail_path=</code></li>
122+
<li>Locate your (fake) <a href="doit:open:Sendmail Path:clipboard">sendmail</a> program and add the path at the end inside "quotes".</li>
123+
</ul>
124+
This gives something like: <code>sendmail_path = "…/…/sendmail"</code>. Paste the resulting path.</li>
125+
<li>While you’re at it, check <a href="doit:find:extension ?= ?.*gd"><code>extension=gd</code></a> and remove the comment(<code>;</code>) at the beginning of the line(if any). This will enable you to use image functions in PHP. </li>
126+
</ol>
109127
</div>
110128
<div class="textarea etc">
111129
<textarea name="content">Open php.ini file or Select Platform</textarea>

package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "edit-virtual-hosts",
3-
"version": "0.6.0",
3+
"version": "0.6.2",
44
"description": "Edit Virtual Hosts",
55
"main": "main.js",
66
"repository": "https://github.com/manngo/edit-virtual-hosts",
@@ -23,7 +23,8 @@
2323
"category": "public.app-category.developer-tools",
2424
"target": [
2525
"zip",
26-
"dmg"
26+
"dmg",
27+
"dir"
2728
],
2829
"icon": "images/edit-virtual-hosts.icns"
2930
},

0 commit comments

Comments
 (0)