fork
Configure Feed
Select the types of activity you want to include in your feed.
nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
fork
Configure Feed
Select the types of activity you want to include in your feed.
1<?xml version="1.0"?>
2
3<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4 xmlns:sdk="http://schemas.android.com/sdk/android/repository/11">
5
6 <xsl:param name="os" />
7 <xsl:output omit-xml-declaration="yes" indent="no" />
8
9 <xsl:template name="repository-url">
10 <xsl:variable name="raw-url" select="sdk:archives/sdk:archive[sdk:host-os=$os or count(sdk:host-os) = 0]/sdk:url"/>
11 <xsl:choose>
12 <xsl:when test="starts-with($raw-url, 'http')">
13 <xsl:value-of select="$raw-url"/>
14 </xsl:when>
15 <xsl:otherwise>
16 <xsl:text>https://dl.google.com/android/repository/</xsl:text>
17 <xsl:value-of select="$raw-url"/>
18 </xsl:otherwise>
19 </xsl:choose>
20 </xsl:template>
21
22 <xsl:template match="/sdk:sdk-repository">
23# This file is generated from generate-platforms.sh. DO NOT EDIT.
24# Execute generate-platforms.sh or fetch.sh to update the file.
25{stdenv, fetchurl, unzip}:
26
27let
28 buildPlatform = args:
29 stdenv.mkDerivation (args // {
30 buildInputs = [ unzip ];
31 buildCommand = ''
32 mkdir -p $out
33 cd $out
34 unzip $src
35 '';
36 });
37in
38{
39 <xsl:for-each select="sdk:platform"><xsl:sort select="sdk:api-level" data-type="number"/>
40 platform_<xsl:value-of select="sdk:api-level" /> = buildPlatform {
41 name = "android-platform-<xsl:value-of select="sdk:version" />";
42 src = fetchurl {
43 url = <xsl:call-template name="repository-url"/>;
44 sha1 = "<xsl:value-of select="sdk:archives/sdk:archive[sdk:host-os=$os or count(sdk:host-os) = 0]/sdk:checksum[@type='sha1']" />";
45 };
46 meta = {
47 description = "<xsl:value-of select="sdk:description" />";
48<xsl:for-each select="sdk:desc-url"> homepage = <xsl:value-of select="." />;</xsl:for-each>
49 };
50 };
51</xsl:for-each>
52}
53</xsl:template>
54</xsl:stylesheet>