Projet

Général

Profil

Paste
Télécharger (1,33 ko) Statistiques
| Branche: | Révision:

root / bin / d7-reset-piwik-variables.sh @ 3b677135

1
#!/bin/sh
2

    
3
###### Common to all sites
4
drush -yq en piwik
5
drush -yq vset piwik_url_http "http://piwik.centrale-marseille.fr/"
6
drush -yq vset piwik_url_https "https://piwik.centrale-marseille.fr/"
7
# Piwik cache.
8
drush -yq vset piwik_cache 1
9
drush -yq vset piwik_visibility_roles "1"
10
# Piwik is enable for everyone except the administrator
11
drush -yq vset --format=json piwik_roles '[3]'
12
drush -yq vset piwik_page_title_hierarchy 1
13
# Activate local search.
14
drush -yq vset piwik_site_search 1
15

    
16
##### Specific
17
# Note: you can read the piwik site id from the url in piwik
18
case $1 in
19
    forumentreprises)
20
	piwik_id=270
21
	;;
22
    fablab)
23
	piwik_id=151
24
	;;
25
    agora)
26
	piwik_id=116
27
	;;
28
    mdv)
29
	piwik_id=99
30
	;;
31
    tvp)
32
	piwik_id=110
33
	;;
34
    bda)
35
	piwik_id=273
36
	;;
37
    bde)
38
	piwik_id=274
39
	;;
40
    bds)
41
	piwik_id=275
42
	;;
43
    cac13)
44
	piwik_id=276
45
	;;
46
    cheer-up)
47
	piwik_id=277
48
	;;
49
    clubfinance)
50
	piwik_id=278
51
	;;
52
    clubrobot)
53
	piwik_id=279
54
	;;
55
    echangesphoceens)
56
	piwik_id=280
57
	;;
58
    eluseleves)
59
	piwik_id=281
60
	;;
61
    ercm)
62
	piwik_id=282
63
	;;
64
    ginfo)
65
	piwik_id=283
66
	;;
67
    icm)
68
	piwik_id=284
69
	;;
70
    isf)
71
	piwik_id=285
72
	;;
73
    ksi)
74
	piwik_id=209
75
	;;
76
    accueil)
77
	piwik_id=286
78
	;;
79
    *)
80
	piwik_id=287
81
	;;
82
esac
83

    
84
# Default is an exception and cannot be treated in the case
85
if echo $1 | grep default ; then
86
    piwik_id=101
87
fi
88

    
89
drush -yq vset piwik_site_id $piwik_id