Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
I
installer
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vnp-framework
installer
Commits
6f4fbd9f
Commit
6f4fbd9f
authored
Feb 18, 2020
by
ntdinh1987
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change repo to github
parent
54081150
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
27 deletions
+28
-27
NewCommand.php
src/NewCommand.php
+28
-27
No files found.
src/NewCommand.php
View file @
6f4fbd9f
...
...
@@ -29,7 +29,8 @@ class NewCommand extends Command
*/
protected
$output
;
protected
$viewZipLink
=
'http://git.vatgia.vn/vnp-framework/view/-/archive/master/view-master.zip'
;
// protected $viewZipLink = 'http://git.vatgia.vn/vnp-framework/view/-/archive/master/view-master.zip';
protected
$viewZipLink
=
'https://github.com/vatgia/vnp-framework/archive/master.zip'
;
protected
$appZipLink
=
'http://git.vatgia.vn/vnp-framework/app/-/archive/master/app-master.zip'
;
...
...
@@ -82,42 +83,42 @@ class NewCommand extends Command
$output
->
writeln
(
'<info>Crafting application...</info>'
);
$output
->
writeln
(
'<info>Download
view
...</info>'
);
$output
->
writeln
(
'<info>Download
code
...</info>'
);
//Download view
$this
->
download
(
$zipFile
=
$this
->
makeFilename
())
->
extract
(
$zipFile
,
$directory
)
->
cleanUp
(
$zipFile
);
$this
->
moveAllFile
(
$directory
.
'/v
iew.git
/'
,
$directory
);
$this
->
rrmdir
(
$directory
.
'/v
iew.git
/'
);
$this
->
moveAllFile
(
$directory
.
'/v
np-framework-master
/'
,
$directory
);
$this
->
rrmdir
(
$directory
.
'/v
np-framework-master
/'
);
$this
->
prepareWritableDirectories
(
$directory
,
$output
);
if
(
!
$input
->
getOption
(
'view'
))
{
$output
->
writeln
(
'<info>Download app...</info>'
);
//Download app
$this
->
downloadApp
(
$zipFile
=
$this
->
makeFilename
())
->
extract
(
$zipFile
,
$directory
.
'/app'
)
->
cleanUp
(
$zipFile
);
$this
->
moveAllFile
(
$directory
.
'/app/app.git/'
,
$directory
.
'/app/'
);
$this
->
rrmdir
(
$directory
.
'/app/app.git/'
);
/**
* Download Database
*/
$output
->
writeln
(
'<info>Download database...</info>'
);
//Download app
$this
->
downloadDatabase
(
$zipFile
=
$this
->
makeFilename
())
->
extract
(
$zipFile
,
$directory
.
'/database'
)
->
cleanUp
(
$zipFile
);
$this
->
moveAllFile
(
$directory
.
'/database/database.git/'
,
$directory
.
'/database/'
);
$this
->
rrmdir
(
$directory
.
'/database/database.git/'
);
}
//
if (!$input->getOption('view')) {
//
//
$output->writeln('<info>Download app...</info>');
//
//Download app
//
$this->downloadApp($zipFile = $this->makeFilename())
//
->extract($zipFile, $directory . '/app')
//
->cleanUp($zipFile);
//
//
$this->moveAllFile($directory . '/app/app.git/', $directory . '/app/');
//
$this->rrmdir($directory . '/app/app.git/');
//
//
/**
//
* Download Database
//
*/
//
$output->writeln('<info>Download database...</info>');
//
//Download app
//
$this->downloadDatabase($zipFile = $this->makeFilename())
//
->extract($zipFile, $directory . '/database')
//
->cleanUp($zipFile);
//
//
$this->moveAllFile($directory . '/database/database.git/', $directory . '/database/');
//
$this->rrmdir($directory . '/database/database.git/');
//
}
$composer
=
$this
->
findComposer
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment