Ce petit tips fonctionne sur un serveur subversion avec un webaccess (usvn, websvn).
Il permet d’exécuter du code Javascript si l’administrateur à mal gérer les permissions de user et les restriction de type mime.
Le fichier Javascript s’appel mypage.html
Il suffit de faire ceci :
$> svn add mypage.html
$> svn propset svn:executable ON ./mypage.html
$> svn propset svn:mime-type text/html ./mypage.html
$> svn commit
Ensuite, on se rend en webaccess sur la page et on l’ouvre ce qui nous donne un joli :
Explication :
1. On ajoute le fichier pour le versionning, jusque la, pas de mystère.
2. La seconde permet de faire un équivalent de chmod +x sur le fichier dans le serveur.
3. On change de mime/type du fichier. C’est le mime-type qui définit l’action a l’ouverture d’un fichier. Normalement, le mime-type des ficheir dans svn sont text/plain, ce qui fait en sorte que e fichier est affiché en brute. La on lui dit d’interpréter le fichier, de “l’exécuter”
Inform@tiquement
Manu404 – Istace Emmanuel
Undeniably believe that which you said. Your favorite reason seemed to
be on the internet the easiest thing to be aware
of. I say to you, I certainly get irked while people consider worries that they just
do not know about. You managed to hit the nail upon
the top as well as defined out the whole thing without
having side-effects , people could take a signal. Will likely be back to
get more. Thanks
Way cool! Some extremely valid points! I appreciate you writing this post
and the rest of the site is also very good.
Having read this I believed it was rather enlightening.
I appreciate you spending some time and effort to put this
short article together. I once again find myself personally spending a significant amount of time both reading and leaving comments.
But so what, it was still worth it!