publishing

vnext
Paul Schneider 7 years ago
parent 2866611cbc
commit b426bc4da9
3 changed files with 15 additions and 13 deletions

@ -3,6 +3,8 @@ PRODDESTDIR=/srv/www/yavsc
ASPNET_ENV=Development
CONFIGURATION=Release
ASPNET_LOG_LEVEL=info #warn
HOSTING=localhost
HOSTADMIN=root
deploy: clean pushInPre pushInProd
@ -46,20 +48,20 @@ bin/output/wwwroot/version: bin/output
@git log -1 --pretty=format:%h > bin/output/wwwroot/version
pushInPre: cleanoutput bin/output/wwwroot/version
ssh root@localhost systemctl stop kestrel-pre
ssh root@localhost rm -rf $(DESTDIR)/approot
(cd bin/output && rsync -ravu ./ root@localhost:$(DESTDIR) >/dev/null)
ssh root@localhost sync
ssh root@localhost systemctl start kestrel-pre
ssh $(HOSTADMIN)@$(HOSTING) service kestrel-pre stop
ssh $(HOSTADMIN)@$(HOSTING) rm -rf $(DESTDIR)/approot
(cd bin/output && rsync -ravu ./ $(HOSTADMIN)@$(HOSTING):$(DESTDIR) >/dev/null)
ssh $(HOSTADMIN)@$(HOSTING) sync
ssh $(HOSTADMIN)@$(HOSTING) service kestrel-pre start
pushInProd: cleanoutput bin/output/wwwroot/version
ifeq ($(git_status),0)
ssh root@localhost systemctl stop kestrel
ssh root@localhost rm -rf $(PRODDESTDIR)/approot
(cd bin/output && rsync -ravu ./ root@localhost:$(PRODDESTDIR) >/dev/null)
ssh root@localhost sync
ssh root@localhost systemctl start kestrel
ssh $(HOSTADMIN)@$(HOSTING) service kestrel stop
ssh $(HOSTADMIN)@$(HOSTING) rm -rf $(PRODDESTDIR)/approot
(cd bin/output && rsync -ravu ./ $(HOSTADMIN)@$(HOSTING):$(PRODDESTDIR) >/dev/null)
ssh $(HOSTADMIN)@$(HOSTING) sync
ssh $(HOSTADMIN)@$(HOSTING) service kestrel start
else
@echo Err! Refus de pousser en production: des changements doivent être validés auprès du contrôle de versions.
@echo EPRODANDGITSTATUS! Refus de pousser en production: des changements doivent être validés auprès du contrôle de versions.
git status
endif

@ -1 +1 @@
.discussion,.notif,.pv{font-family:monospace}#targets,.userinfo{display:block}.blog a:active,.blog a:hover,a:active,a:hover{outline:0}#discussion,.blogphoto{float:left}.navbar-brand,.navbar-link,.navbar-nav .dropdown>a{background-color:rgba(0,0,0,.2);border-radius:2em;vertical-align:center}.navbar-brand:focus,.navbar-brand:hover,.navbar-link:focus,.navbar-link:hover{background-color:rgba(0,0,0,.4)}.ql-editor{border:1em outset #ee903e;padding:1em}.badge{margin:1em}.badge img{height:2em}.userinfo{padding:.8em .8em .8em 2em;margin:.6em;background-repeat:no-repeat;background-attachment:local;background-size:contain;background-image:url(/images/lis.svg);overflow:auto}.performer{border-radius:1.5em;background-color:#f1e4f1;padding:1em}.performer ul{margin-left:2.5em}.smalltofhol{align-self:left;padding:.1em;border-radius:50%}.commentmeta{margin:.5em;padding:.5em;border-right:#444 dashed 1px;border-top:#444 solid 1px}.price,.total{font-weight:700;padding:.2em;margin:.2em}.price{font-size:large}.total{font-size:xx-large;background-color:#f8f;border:3px solid #000;border-radius:1em}.blog,.panel{padding:1em}.blog a{font-weight:900}.discussion{color:#000}.notif{color:#006}.pv{color:#251;font-style:bold}tr.visiblepost,tr.visiblepost img{max-height:3em}tr.hiddenpost{max-height:2em;background-color:#888;font-size:smaller}tr.hiddenpost img{max-height:3em}a.bloglink{font-weight:700;text-shadow:0 0 8px #000}a{font-weight:900}.panel{display:inline-block;margin:1em;color:#000;background-color:inherit;border:1px solid #000}button,input,select,textarea{background-color:#bbb;color:#000}.jumbotron{padding:.5em}.carousel .item .carousel-caption-s{-webkit-transition:-webkit-transform 2s background-color 2s color 2s;-moz-transition:transform 2s background-color 2s color 2s;transition:transform 2s;transform:scale3d(0,0,0);-webkit-transform:scale3d(0,0,0)}.carousel .item.active .carousel-caption-s{-webkit-transform:scale3d(1,1,1);transform:scale3d(1,1,1)}.disabled{color:#999;background-color:#555}.smallphoto{max-height:4em}.carousel-caption-s p{-webkit-text-shadow:3px 3px 7px #000;animation:mymove 4s infinite;font-family:Arial;font-weight:800;font-size:x-large;text-shadow:3px 3px 7px #00003c;color:#fff;background-color:rgba(94,24,194,.15);border-radius:.5em}.carousel-caption-s{right:3em;top:1em;left:3em;z-index:10;padding-top:20px;padding-bottom:20px;text-align:center;min-height:16em;overflow:auto}.carousel-inner .item{padding-left:15%;padding-right:15%}.carousel-indicators{position:absolute;z-index:15;padding:0;text-align:center;list-style:none;top:.1em;height:1em}main.container{padding-right:1em;padding-left:1em;margin-left:1em;margin-right:1em}@media (max-width:767px){main.container{padding-right:.3em;padding-left:.3em;margin-left:.3em;margin-right:.3em}.navbar-brand{float:left;height:50px;padding:5px;font-size:16px;line-height:18px}.carousel-caption-s p{margin:.2em;padding:.2em}}@-webkit-keyframes mymove{from,to{text-decoration-color:red}50%{text-decoration-color:#00f}}@keyframes mymove{from,to{text-decoration-color:red}50%{text-decoration-color:#00f}}ul.actiongroup li{display:inline}ul.actiongroup li a:hover{background-color:rgba(200,200,200,.6);color:#400}footer{vertical-align:bottom;padding:1.5em}.display-field{font-kerning:none;display:inline-flex;color:#008}.display-label{font-family:'Lucida Sans','Lucida Sans Regular','Lucida Grande','Lucida Sans Unicode',Geneva,Verdana,sans-serif;font-stretch:condensed;display:inline-flex;color:#ff8;padding:.1em;border-radius:.5em;background-color:#210912}footer{color:grey;font-weight:bolder;font-size:x-small}.meta{color:#444;font-style:italic;font-size:smaller}.activity{font-family:fantasy}.blogtitle{display:inline-block;font-size:x-large}.blogphoto{margin:1em}.dl-horizontal dd{margin-left:20%}
.discussion,.notif,.pv{font-family:monospace}#targets,.userinfo{display:block}.blog a:active,.blog a:hover,a:active,a:hover{outline:0}#discussion,.blogphoto{float:left}.navbar-brand,.navbar-link,.navbar-nav .dropdown>a{background-color:rgba(0,0,0,.2);border-radius:2em;vertical-align:center}.navbar-brand:focus,.navbar-brand:hover,.navbar-link:focus,.navbar-link:hover{background-color:rgba(0,0,0,.4)}.blogcomment{border:.2em outset grey}.ql-editor{border:1em outset #ee903e;padding:1em}.badge{margin:1em}.badge img{height:2em}.userinfo{padding:.8em .8em .8em 2em;margin:.6em;background-repeat:no-repeat;background-attachment:local;background-size:contain;background-image:url(/images/lis.svg);overflow:auto}.performer{border-radius:1.5em;background-color:#f1e4f1;padding:1em}.performer ul{margin-left:2.5em}.smalltofhol{align-self:left;padding:.1em;border-radius:50%}.commentmeta{margin:.5em;padding:.5em;border-right:#444 dashed 1px;border-top:#444 solid 1px}.price,.total{font-weight:700;padding:.2em;margin:.2em}.price{font-size:large}.total{font-size:xx-large;background-color:#f8f;border:3px solid #000;border-radius:1em}.blog,.panel{padding:1em}.blog a{font-weight:900}.discussion{color:#000}.notif{color:#006}.pv{color:#251;font-style:bold}tr.visiblepost,tr.visiblepost img{max-height:3em}tr.hiddenpost{max-height:2em;background-color:#888;font-size:smaller}tr.hiddenpost img{max-height:3em}a.bloglink{font-weight:700;text-shadow:0 0 8px #000}a{font-weight:900}.panel{display:inline-block;margin:1em;color:#000;background-color:inherit;border:1px solid #000}button,input,select,textarea{background-color:#bbb;color:#000}.jumbotron{padding:.5em}.carousel .item .carousel-caption-s{-webkit-transition:-webkit-transform 2s background-color 2s color 2s;-moz-transition:transform 2s background-color 2s color 2s;transition:transform 2s;transform:scale3d(0,0,0);-webkit-transform:scale3d(0,0,0)}.carousel .item.active .carousel-caption-s{-webkit-transform:scale3d(1,1,1);transform:scale3d(1,1,1)}.disabled{color:#999;background-color:#555}.smallphoto{max-height:4em}.carousel-caption-s p{-webkit-text-shadow:3px 3px 7px #000;animation:mymove 4s infinite;font-family:Arial;font-weight:800;font-size:x-large;text-shadow:3px 3px 7px #00003c;color:#fff;background-color:rgba(94,24,194,.15);border-radius:.5em}.carousel-caption-s{right:3em;top:1em;left:3em;z-index:10;padding-top:20px;padding-bottom:20px;text-align:center;min-height:16em;overflow:auto}.carousel-inner .item{padding-left:15%;padding-right:15%}.carousel-indicators{position:absolute;z-index:15;padding:0;text-align:center;list-style:none;top:.1em;height:1em}main.container{padding-right:1em;padding-left:1em;margin-left:1em;margin-right:1em}@media (max-width:767px){main.container{padding-right:.3em;padding-left:.3em;margin-left:.3em;margin-right:.3em}.navbar-brand{float:left;height:50px;padding:5px;font-size:16px;line-height:18px}.carousel-caption-s p{margin:.2em;padding:.2em}}@-webkit-keyframes mymove{from,to{text-decoration-color:red}50%{text-decoration-color:#00f}}@keyframes mymove{from,to{text-decoration-color:red}50%{text-decoration-color:#00f}}ul.actiongroup li{display:inline}ul.actiongroup li a:hover{background-color:rgba(200,200,200,.6);color:#400}footer{vertical-align:bottom;padding:1.5em}.display-field{font-kerning:none;display:inline-flex;color:#008}.display-label{font-family:'Lucida Sans','Lucida Sans Regular','Lucida Grande','Lucida Sans Unicode',Geneva,Verdana,sans-serif;font-stretch:condensed;display:inline-flex;color:#ff8;padding:.1em;border-radius:.5em;background-color:#210912}footer{color:grey;font-weight:bolder;font-size:x-small}.meta{color:#444;font-style:italic;font-size:smaller}.activity{font-family:fantasy}.blogtitle{display:inline-block;font-size:x-large}.blogphoto{margin:1em}.dl-horizontal dd{margin-left:20%}

@ -1 +1 @@
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(e){e.widget("psc.blogcomment",{options:{apictrlr:null,omob:"#ffe08030",omof:"#501208",bgc:"#fff",fgc:"#000",lang:"fr-FR"},editable:!1,editting:!1,edctrl:null,_create:function(){var e=this;this.element.addClass("blogcomment");var t=new Date(this.element.data("date")),o=this.element.data("username");this.editable=this.element.data("allow-edit"),this.element.prepend('<div class="commentmeta"><div class="avatar"><img src="/Avatars/'+o+'.xs.png" class="smalltofhol" />'+o+'</div><div class="cmtdatetime">'+t.toLocaleDateString(this.options.lang)+" "+t.toLocaleTimeString(this.options.lang)+"</div></div>"),this.element.on("mouseenter",this.onMouseEnter),this.element.on("mouseleave",this.onMouseLeave),this.editable&&this.element.on("click",function(t){e.toggleEdit(e,t)})},toggleEdit:function(t,o){t.edctrl?(t.edctrl.remove(),t.edctrl=null):(t.edctrl=e('<button class="btn btn-default">Delete</button>'),t.edctrl.on("click",function(e){t.doDeleteComment(t,e)}).appendTo(t.element))},onMouseEnter:function(){e(this).animate({backgroundColor:e.psc.blogcomment.prototype.options.omob,color:e.psc.blogcomment.prototype.options.omof},400)},onMouseLeave:function(){e(this).animate({backgroundColor:e.psc.blogcomment.prototype.options.bgc,color:e.psc.blogcomment.prototype.options.fgc},400)},doDeleteComment:function(t,o){var n=e(t.element).data("id"),a=t.options.apictrlr;e.ajax({async:!0,cache:!1,type:"POST",method:"DELETE",error:function(t,o){e('span.field-validation-valid[data-valmsg-for="Content"]').html("Une erreur est survenue : "+t.status+"<br/>").focus()},success:function(e){t.element.remove()},url:a+"/"+n})}}),e(document).ready(function(){e("[data-type='blogcomment']").blogcomment()})}(jQuery);
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(t){t.widget("psc.blogcomment",{options:{apictrlr:null,authorId:null,authorName:null,omob:"#ffe08030",omof:"#501208",bgc:"#fff",fgc:"#000",lang:"fr-FR",allowCoc:!0},editable:!1,editting:!1,hideBtn:null,delBtn:null,cmtInput:null,cmtBtn:null,ctlBtn:null,collapsed:!1,subCmts:null,_create:function(){var e=this;this.element.addClass("blogcomment");var o=new Date(this.element.data("date")),n=this.element.data("username");this.editable=this.element.data("allow-edit"),this.element.prepend('<div class="commentmeta"><div class="avatar"><img src="/Avatars/'+n+'.xs.png" class="smalltofhol" />'+n+'</div><div class="cmtdatetime">'+o.toLocaleDateString(this.options.lang)+" "+o.toLocaleTimeString(this.options.lang)+"</div></div>"),this.element.on("mouseenter",this.onMouseEnter),this.element.on("mouseleave",this.onMouseLeave),this.ctlBtn=t('<button class="btn glyphicon-collapse-down"></button>').on("click",function(t){e.toggleCollapse(e,t)}).appendTo(e.element)},toggleCollapse:function(e,o){e.collapsed=!e.collapsed,e.collapsed?(t(e.ctlBtn).removeClass("glyphicon-collapse-down"),t(e.ctlBtn).addClass("glyphicon-collapse-up")):(t(e.ctlBtn).removeClass("glyphicon-collapse-up"),t(e.ctlBtn).addClass("glyphicon-collapse-down")),e.editable&&e.toggleEdit(e,o),e.options.allowCoc&&e.toggleComment(e,o)},toggleEdit:function(e,o){e.delBtn?(e.delBtn.remove(),e.delBtn=null):(e.delBtn=t('<button class="btn btn-warning">Supprimer</button>'),e.delBtn.on("click",function(t){e.doDeleteComment(e,t)}).appendTo(e.element))},toggleComment:function(e,o){e.cmtBtn?(e.cmtInput.remove(),e.cmtBtn.remove(),e.cmtBtn=null):(e.subCmts||(e.subCmts=t(e.element).children("div.subcomments"),0==e.subCmts.length&&(e.subCmts=t("<div></div>").addClass("subcomments"),e.subCmts.appendTo(e.element))),e.cmtInput=t('<input type="text" placeholder="Votre réponse"/>'),e.cmtInput.appendTo(e.element),e.cmtBtn=t('<button class="btn btn-default">Répondre</button>'),e.cmtBtn.on("click",function(t){e.doCoC(e,t)}).appendTo(e.element))},onMouseEnter:function(){t(this).animate({backgroundColor:t.psc.blogcomment.prototype.options.omob,color:t.psc.blogcomment.prototype.options.omof},400)},onMouseLeave:function(){t(this).animate({backgroundColor:t.psc.blogcomment.prototype.options.bgc,color:t.psc.blogcomment.prototype.options.fgc},400)},doDeleteComment:function(e,o){var n=t(e.element).data("id"),l=e.options.apictrlr;t.ajax({async:!0,cache:!1,type:"POST",method:"DELETE",error:function(e,o){t('span.field-validation-valid[data-valmsg-for="Content"]').html("Une erreur est survenue : "+e.status+"<br/>").focus()},success:function(t){e.element.remove()},url:l+"/"+n})},doCoC:function(e,o){var n=t("#cmtBtn").data("receiverid"),l=e.cmtInput.val(),a=t(e.element).data("id"),s={Content:l,PostId:n,ParentId:a,AuthorId:e.options.authorId};t.ajax({async:!0,cache:!1,type:"POST",method:"POST",contentType:"application/json",data:JSON.stringify(s),error:function(e,o){console.log("err"),console.log(e),console.log(o),t('span.field-validation-valid[data-valmsg-for="Content"]').html("Une erreur est survenue : "+e.status+"<br/><code><pre>"+e.responseText+"</pre></code>")},success:function(o){var n=o.Content;e.cmtInput.val(""),t('span.field-validation-valid[data-valmsg-for="Content"]').empty();var l=htmlize(n);t('<div data-type="blogcomment" data-id="'+o.Id+'" data-allow-edit="True" data-date="'+o.DateCreated+'" data-username="'+e.options.authorName+'">'+l+"</div>").blogcomment().appendTo(e.subCmts)},url:e.options.apictrlr})}}),t(document).ready(function(){t("[data-type='blogcomment']").blogcomment()})}(jQuery);
Loading…