
Recherche avancée
Médias (1)
-
Richard Stallman et le logiciel libre
19 octobre 2011, par
Mis à jour : Mai 2013
Langue : français
Type : Texte
Autres articles (76)
-
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...) -
Récupération d’informations sur le site maître à l’installation d’une instance
26 novembre 2010, parUtilité
Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...) -
Contribute to a better visual interface
13 avril 2011MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.
Sur d’autres sites (6791)
-
Anomalie #4425 (Nouveau) : Des bots chinois comptabilisés dans les statistiques
21 janvier 2020Bonjour,
Je reporte ici un message trouvé sur la liste user.
Le fichier /ecrire/inc_version.php inclut un certain nombre de bots à ne pas comptabiliser. Je suggère d’ajouter une liste de bots chinois et russes :
Mb2345Browser
LieBaoFast
zh-CN
MicroMessenger
zh_CN
KinzaCes bots explosent littéralement mes stats avec des dizaines de milliers de visites comptabilisées.
J’ai fait l’ajout manuellement mais la prochaine mise-à-jour de SPIP les effacera.
Merci
Guilain
Au passage, je suggère de faire comme avec : https://zone.spip.net/trac/spip-zone/browser/spip-zone/_core_/plugins/statistiques/engines-list.txt
Donc, une liste qui soit maintenue dans un fichier texte, facile à mettre à jour. -
receiving ffmpeg udp output stream data using C socket
11 février 2021, par g KishoreI am sending TS data from file(1880V.ts) on UDP using ffmpeg with the following command


- 

- ffmpeg -re -i 1880V.ts -f mpegts udp ://192.168.47.172:10500




Note : 192.168.47.172 is local ubuntu machine's local IP address.


I am trying to capture the above stream using C socket on the same machine.


Following is the C socket program to receive the TS.


- 

- recvfrom not able to receive the data




#include 
#include 
#include 
#include 
#include 
#include 
#include <sys></sys>types.h>
#include <netinet></netinet>in.h>
#include <sys></sys>socket.h>
#include <arpa></arpa>inet.h>

#define PORT 10500

int main(int argc, char **argv){

 int sockfd, received_bytes;//, sended_bytes;
 unsigned char buffer[1024];//, buffer_to_send[1024];

 struct sockaddr_in remote_addr;

 socklen_t slen = sizeof(remote_addr);

 remote_addr.sin_family = AF_INET;
 remote_addr.sin_port = htons(PORT);
 remote_addr.sin_addr.s_addr = inet_addr("192.168.47.172");
 memset(remote_addr.sin_zero, '\0', sizeof(remote_addr.sin_zero));
 
 if((sockfd = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)) == -1){
 perror("Socket ");
 exit(1);
 }
 else
 printf("socket created successfully\n");
 while(1)
 {
 /*
 int remote_connect = connect(sockfd, (struct sockaddr *)&remote_addr, sizeof(struct sockaddr));
 if(remote_connect < 0){
 perror("Connect ");
 exit(1);
 }
 else
 perror("connected successfully. \n");
 */
 if((received_bytes = recvfrom(sockfd, buffer, sizeof(buffer), 0, (struct sockaddr *)&remote_addr, &slen)) == -1){
 perror("Recv ");
 exit(1);
 }
 }
return 0;
}



I got stuck up here. Kindly help me to resolve the issue.


-
Restart environment and script during batch script
7 décembre 2024, par ninburaI've built a few FFmpeg powershell scripts for me and a few others to use and I'm attempting to make the setup and update process as easy as possible. The end goal is to be able to run 1 batch file that installs Chocolatey, FFmpeg, git, clones the github repo (for updates), and edits the Windows registry to add the actual FFmpeg powershell scripts / console programs to the Windows Explorer contextual menu. This way I just pass them the folder containing everything once and any time I change or add something to the project I can just tell them to run the batch file again, and presto everything is up to date.



However I'm struggling to find a way to install Chocolatey, then git with Chocolatey, and then run a git command with the execution of a single .bat file. From what I can tell after installing Chocolatey I need to restart the shell entirely before I can install git, and then I have to restart the shell again before I can use a git command. As of right now most of the actual processing is happening via Powershell scripts that are launched from the .bat file, and as each step is taken I update a txt file, attempt to restart the batch script, and read the txt file to pick up where I left off :



@echo off
echo Administrative permissions required. Detecting permissions...
echo.

net session >nul 2>&1
if %errorLevel% == 0 (
 echo Success: Administrative permissions confirmed.
 echo.
) else (
 echo Failure: Current permissions inadequate.

 PAUSE

 exit
)

set relativePath=%~dp0
set relativePath=%relativePath:~0,-1%

PowerShell -NoProfile -ExecutionPolicy Bypass -File "%relativePath%\Setup\CheckRequiredPackages.ps1" -relativePath "%relativePath%"

set /p step=<"%relativePath%\Setup\Step.txt"

if %step% == 1 (
 (echo 2) > "%relativePath%\Setup\Step.txt"

 PowerShell -NoProfile -ExecutionPolicy Bypass -File "%relativePath%\Setup\GetChocolatey.ps1"

 start "" "%relativePath%\RunMe.bat"

 exit
) 

if %step% == 2 (
 (echo 3) > "%relativePath%\Setup\Step.txt"

 PowerShell -NoProfile -ExecutionPolicy Bypass -File "%relativePath%\Setup\GetRequiredPackages.ps1"

 start "" "%relativePath%\RunMe.bat"

 exit
) 

if %step% == 3 (
 (echo 0) > "%relativePath%\Setup\Step.txt"

 PowerShell -NoProfile -ExecutionPolicy Bypass -File "%relativePath%\Setup\Update.ps1" -relativePath "%relativePath%"
) 

PAUSE
Exit




The problem is using the
start
command in the batch script doesn't seem to work, I'm guessing since that new process is spawned from the same process that handles the Chocolatey install it doesn't count as actually restarting the shell. Is there any way to actually restart the shell and somehow have the batch file start back up without user intervention ?